API Overview API Index Package Overview Direct link to this page
JDK 1.6
  javax.swing. DebugGraphics View Source
Author(s)
Dave Karlton
Since
Version
1.27 11/17/05
Serial
Hierarchy
 Object
      Graphics
          DebugGraphics
Implements
Subclasses
Description
public class DebugGraphics
  Graphics subclass supporting graphics debugging.
Constructors
public DebugGraphics ()
Constructs a new debug graphics context that supports slowed down drawing.
public DebugGraphics (Graphics graphics)
  Constructs a debug graphics context from an existing graphics context that supports slowed down drawing.
public DebugGraphics (Graphics graphics, JComponent component)
  Constructs a debug graphics context from an existing graphics context that slows down drawing for the specified component.
Methods
Hide/Show inherited methods
public void clearRect (int x, int y, int width, int height) [Specified in Graphics]
Overrides Graphics.clearRect.
public void clipRect (int x, int y, int width, int height) [Specified in Graphics]
Overrides Graphics.clipRect.
public void copyArea (int x, int y, int width, int height, int destX, int destY) [Specified in Graphics]
Overrides Graphics.copyArea.
public Graphics create () [Specified in Graphics]
Overrides Graphics.create to return a DebugGraphics object.
public Graphics create (int x, int y, int width, int height) [Overrides Graphics]
Overrides Graphics.create to return a DebugGraphics object.
pack-private boolean debugBuffered ()
pack-privatestatic int debugComponentCount ()
Returns the number of JComponents that have debugging options turned on.
pack-private boolean debugFlash ()
pack-private boolean debugLog ()
public void dispose () [Specified in Graphics]
Overrides Graphics.dispose.
public void draw3DRect (int x, int y, int width, int height, boolean raised) [Overrides Graphics]
Overrides Graphics.draw3DRect.
public void drawArc (int x, int y, int width, int height, int startAngle, int arcAngle) [Specified in Graphics]
Overrides Graphics.drawArc.
public void drawBytes (byte[] data, int offset, int length, int x, int y) [Overrides Graphics]
Overrides Graphics.drawBytes.
public void drawChars (char[] data, int offset, int length, int x, int y) [Overrides Graphics]
Overrides Graphics.drawChars.
public boolean drawImage (Image img, int x, int y, Color bgcolor, ImageObserver observer) [Specified in Graphics]
Overrides Graphics.drawImage.
public boolean drawImage (Image img, int x, int y, ImageObserver observer) [Specified in Graphics]
Overrides Graphics.drawImage.
public boolean drawImage (Image img, int x, int y, int width, int height, Color bgcolor, ImageObserver observer) [Specified in Graphics]
Overrides Graphics.drawImage.
public boolean drawImage (Image img, int x, int y, int width, int height, ImageObserver observer) [Specified in Graphics]
Overrides Graphics.drawImage.
public boolean drawImage (Image img, int dx1, int dy1, int dx2, int dy2, int sx1, int sy1, int sx2, int sy2, Color bgcolor, ImageObserver observer) [Specified in Graphics]
Overrides Graphics.drawImage.
public boolean drawImage (Image img, int dx1, int dy1, int dx2, int dy2, int sx1, int sy1, int sx2, int sy2, ImageObserver observer) [Specified in Graphics]
Overrides Graphics.drawImage.
public void drawLine (int x1, int y1, int x2, int y2) [Specified in Graphics]
Overrides Graphics.drawLine.
public void drawOval (int x, int y, int width, int height) [Specified in Graphics]
Overrides Graphics.drawOval.
public void drawPolygon (int[] xPoints, int[] yPoints, int nPoints) [Specified in Graphics]
Overrides Graphics.drawPolygon.
public void drawPolygon (Polygon p) [Inherited From Graphics]
  Draws the outline of a polygon defined by the specified Polygon object.
public void drawPolyline (int[] xPoints, int[] yPoints, int nPoints) [Specified in Graphics]
Overrides Graphics.drawPolyline.
public void drawRect (int x, int y, int width, int height) [Overrides Graphics]
Overrides Graphics.drawRect.
public void drawRoundRect (int x, int y, int width, int height, int arcWidth, int arcHeight) [Specified in Graphics]
Overrides Graphics.drawRoundRect.
public void drawString (AttributedCharacterIterator iterator, int x, int y) [Specified in Graphics]
Overrides Graphics.drawString.
public void drawString (String aString, int x, int y) [Specified in Graphics]
Overrides Graphics.drawString.
public void fill3DRect (int x, int y, int width, int height, boolean raised) [Overrides Graphics]
Overrides Graphics.fill3DRect.
public void fillArc (int x, int y, int width, int height, int startAngle, int arcAngle) [Specified in Graphics]
Overrides Graphics.fillArc.
public void fillOval (int x, int y, int width, int height) [Specified in Graphics]
Overrides Graphics.fillOval.
public void fillPolygon (int[] xPoints, int[] yPoints, int nPoints) [Specified in Graphics]
Overrides Graphics.fillPolygon.
public void fillPolygon (Polygon p) [Inherited From Graphics]
  Fills the polygon defined by the specified Polygon object with the graphics context's current color.
public void fillRect (int x, int y, int width, int height) [Specified in Graphics]
Overrides Graphics.fillRect.
public void fillRoundRect (int x, int y, int width, int height, int arcWidth, int arcHeight) [Specified in Graphics]
Overrides Graphics.fillRoundRect.
public void finalize () [Inherited From Graphics]
  Disposes of this graphics context once it is no longer referenced.
publicstatic Color flashColor ()
  Returns the Color used to flash drawing operations.
publicstatic int flashCount ()
  Returns the number of times that drawing operations will flash.
publicstatic int flashTime ()
  Returns the time delay of drawing operation flashing.
public Shape getClip () [Specified in Graphics]
Overrides Graphics.getClip.
public Rectangle getClipBounds () [Specified in Graphics]
Overrides Graphics.getClipBounds.
public Rectangle getClipBounds (Rectangle r) [Inherited From Graphics]
  Returns the bounding rectangle of the current clipping area.
@Deprecated
public Rectangle getClipRect () [Inherited From Graphics]
  Returns the bounding rectangle of the current clipping area.
public Color getColor () [Specified in Graphics]
  Returns the Color used for text drawing operations.
public int getDebugOptions ()
  Returns the current debugging options for this DebugGraphics.
pack-privatestatic int getDebugOptions (JComponent component)
Static wrapper method for DebugGraphicsInfo.getDebugOptions().
public Font getFont () [Specified in Graphics]
  Returns the Font used for text drawing operations.
public FontMetrics getFontMetrics () [Overrides Graphics]
Overrides Graphics.getFontMetrics.
public FontMetrics getFontMetrics (Font f) [Specified in Graphics]
Overrides Graphics.getFontMetrics.
public boolean hitClip (int x, int y, int width, int height) [Inherited From Graphics]
  Returns true if the specified rectangular area might intersect the current clipping area.
pack-privatestatic DebugGraphicsInfo info ()
Returns DebugGraphicsInfo, or creates one if none exists.
public boolean isDrawingBuffer ()
  Returns the drawingBuffer value.
pack-privatestatic void loadImage (Image img)
publicstatic PrintStream logStream ()
  Returns the stream to which the DebugGraphics logs drawing operations.
pack-private String pointToString (int x, int y)
public void setClip (int x, int y, int width, int height) [Specified in Graphics]
Overrides Graphics.setClip.
public void setClip (Shape clip) [Specified in Graphics]
Overrides Graphics.setClip.
public void setColor (Color aColor) [Specified in Graphics]
Sets the color to be used for drawing and filling lines and shapes.
public void setDebugOptions (int options)
  Enables/disables diagnostic information about every graphics operation.
pack-privatestatic void setDebugOptions (JComponent component, int options)
  Static wrapper method for DebugGraphicsInfo.setDebugOptions().
publicstatic void setFlashColor (Color flashColor)
Sets the Color used to flash drawing operations.
publicstatic void setFlashCount (int flashCount)
Sets the number of times that drawing operations will flash.
publicstatic void setFlashTime (int flashTime)
Sets the time delay of drawing operation flashing.
public void setFont (Font aFont) [Specified in Graphics]
Sets the Font used for text drawing operations.
publicstatic void setLogStream (PrintStream stream)
Sets the stream to which the DebugGraphics logs drawing operations.
public void setPaintMode () [Specified in Graphics]
Overrides Graphics.setPaintMode.
public void setXORMode (Color aColor) [Specified in Graphics]
Overrides Graphics.setXORMode.
pack-privatestatic int shouldComponentDebug (JComponent component)
  Returns non-zero if component should display with DebugGraphics, zero otherwise.
pack-privatefinal void sleep (int mSecs)
pack-private String toShortString ()
public String toString () [Inherited From Graphics]
  Returns a String object representing this Graphics object's value.
public void translate (int x, int y) [Specified in Graphics]
Overrides Graphics.translate.
Fields
Hide/Show inherited fields
pack-private Image buffer
publicfinalstatic int BUFFERED_OPTION = "4"
Show buffered operations in a separate Frame.
pack-private int debugOptions
publicfinalstatic int FLASH_OPTION = "2"
Flash graphics operations.
pack-private Graphics graphics
pack-private int graphicsID
publicfinalstatic int LOG_OPTION = "1"
Log graphics operations.
publicfinalstatic int NONE_OPTION = "-1"
Don't debug graphics operations.
pack-private int xOffset
pack-private int yOffset
Nested Classes
Generated By: JavaOnTracks Doclet 0.1.4     ©Thibaut Colar