Save This Page
Home » openjdk-7 » javax » swing » [javadoc | source]
javax.swing
public class: DebugGraphics [javadoc | source]
java.lang.Object
   java.awt.Graphics
      javax.swing.DebugGraphics
An extension of Graphics that can be used for debugging custom Swing widgets. DebugGraphics has the ability to draw slowly and can log drawing actions.
Field Summary
public static final  int LOG_OPTION    LOG_OPTION 
public static final  int FLASH_OPTION    FLASH_OPTION 
public static final  int BUFFERED_OPTION    BUFFERED_OPTION 
public static final  int NONE_OPTION    NONE_OPTION 
static  Color debugFlashColor     
static  int debugFlashCount     
static  int debugFlashTime     
static  PrintStream debugLogStream     
static  int counter    Counts the created DebugGraphics objects. This is used by the logging facility. 
 Graphics graphics    graphics 
 Image buffer    buffer 
 int debugOptions    debugOptions 
 int graphicsID    graphicsID 
 int xOffset    xOffset 
 int yOffset    yOffset 
Constructor:
 public DebugGraphics() 
 public DebugGraphics(Graphics graphics) 
    Creates a DebugGraphics object.
    Parameters:
    graphics - The Graphics object to wrap
 public DebugGraphics(Graphics graphics,
    JComponent component) 
    Creates a DebugGraphics object.
    Parameters:
    graphics - The Graphics object to wrap
    component - TODO
Method from javax.swing.DebugGraphics Summary:
clearRect,   clipRect,   copyArea,   create,   create,   dispose,   draw3DRect,   drawArc,   drawBytes,   drawChars,   drawImage,   drawImage,   drawImage,   drawImage,   drawImage,   drawImage,   drawLine,   drawOval,   drawPolygon,   drawPolyline,   drawRect,   drawRoundRect,   drawString,   drawString,   fill3DRect,   fillArc,   fillOval,   fillPolygon,   fillRect,   fillRoundRect,   flashColor,   flashCount,   flashTime,   getClip,   getClipBounds,   getColor,   getDebugOptions,   getFont,   getFontMetrics,   getFontMetrics,   isDrawingBuffer,   logStream,   setClip,   setClip,   setColor,   setDebugOptions,   setFlashColor,   setFlashCount,   setFlashTime,   setFont,   setLogStream,   setPaintMode,   setXORMode,   translate
Methods from java.awt.Graphics:
clearRect,   clipRect,   copyArea,   create,   create,   dispose,   draw3DRect,   drawArc,   drawBytes,   drawChars,   drawImage,   drawImage,   drawImage,   drawImage,   drawImage,   drawImage,   drawLine,   drawOval,   drawPolygon,   drawPolygon,   drawPolyline,   drawRect,   drawRoundRect,   drawString,   drawString,   fill3DRect,   fillArc,   fillOval,   fillPolygon,   fillPolygon,   fillRect,   fillRoundRect,   finalize,   getClip,   getClipBounds,   getClipBounds,   getClipRect,   getColor,   getFont,   getFontMetrics,   getFontMetrics,   hitClip,   setClip,   setClip,   setColor,   setFont,   setPaintMode,   setXORMode,   toString,   translate
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from javax.swing.DebugGraphics Detail:
 public  void clearRect(int x,
    int y,
    int width,
    int height) 
    clearRect
 public  void clipRect(int x,
    int y,
    int width,
    int height) 
    Intersects the current clip region with the given region.
 public  void copyArea(int x,
    int y,
    int width,
    int height,
    int destx,
    int desty) 
    copyArea
 public Graphics create() 
    Creates a overrides Graphics.create to create a DebugGraphics object.
 public Graphics create(int x,
    int y,
    int width,
    int height) 
    Creates a overrides Graphics.create to create a DebugGraphics object.
 public  void dispose() 
    Releases all system resources that this Graphics is using.
 public  void draw3DRect(int x,
    int y,
    int width,
    int height,
    boolean raised) 
    draw3DRect
 public  void drawArc(int x,
    int y,
    int width,
    int height,
    int startAngle,
    int arcAngle) 
    drawArc
 public  void drawBytes(byte[] data,
    int offset,
    int length,
    int x,
    int y) 
    drawBytes
 public  void drawChars(char[] data,
    int offset,
    int length,
    int x,
    int y) 
    drawChars
 public boolean drawImage(Image image,
    int x,
    int y,
    ImageObserver observer) 
    drawImage
 public boolean drawImage(Image image,
    int x,
    int y,
    Color background,
    ImageObserver observer) 
    drawImage
 public boolean drawImage(Image image,
    int x,
    int y,
    int width,
    int height,
    ImageObserver observer) 
    drawImage
 public boolean drawImage(Image image,
    int x,
    int y,
    int width,
    int height,
    Color background,
    ImageObserver observer) 
    drawImage
 public boolean drawImage(Image image,
    int dx1,
    int dy1,
    int dx2,
    int dy2,
    int sx1,
    int sy1,
    int sx2,
    int sy2,
    ImageObserver observer) 
    drawImage
 public boolean drawImage(Image image,
    int dx1,
    int dy1,
    int dx2,
    int dy2,
    int sx1,
    int sy1,
    int sx2,
    int sy2,
    Color background,
    ImageObserver observer) 
    drawImage
 public  void drawLine(int x1,
    int y1,
    int x2,
    int y2) 
    drawLine
 public  void drawOval(int x,
    int y,
    int width,
    int height) 
    drawOval
 public  void drawPolygon(int[] xpoints,
    int[] ypoints,
    int npoints) 
    drawPolygon
 public  void drawPolyline(int[] xpoints,
    int[] ypoints,
    int npoints) 
    drawPolyline
 public  void drawRect(int x,
    int y,
    int width,
    int height) 
    Draws a rectangle.
 public  void drawRoundRect(int x,
    int y,
    int width,
    int height,
    int arcWidth,
    int arcHeight) 
    drawRoundRect
 public  void drawString(String string,
    int x,
    int y) 
    drawString
 public  void drawString(AttributedCharacterIterator iterator,
    int x,
    int y) 
    drawString
 public  void fill3DRect(int x,
    int y,
    int width,
    int height,
    boolean raised) 
    fill3DRect
 public  void fillArc(int x,
    int y,
    int width,
    int height,
    int startAngle,
    int arcAngle) 
    fillArc
 public  void fillOval(int x,
    int y,
    int width,
    int height) 
    fillOval
 public  void fillPolygon(int[] xpoints,
    int[] ypoints,
    int npoints) 
    fillPolygon
 public  void fillRect(int x,
    int y,
    int width,
    int height) 
    Draws a filled rectangle.
 public  void fillRoundRect(int x,
    int y,
    int width,
    int height,
    int arcWidth,
    int arcHeight) 
    fillRoundRect
 public static Color flashColor() 
    flashColor
 public static int flashCount() 
    flashCount
 public static int flashTime() 
    flashTime
 public Shape getClip() 
    Returns the current clipping region.
 public Rectangle getClipBounds() 
    getClipBounds
 public Color getColor() 
    Returns the color used for drawing.
 public int getDebugOptions() 
    getDebugOptions
 public Font getFont() 
    getFont
 public FontMetrics getFontMetrics() 
    Returns the font metrics of the current font.
 public FontMetrics getFontMetrics(Font font) 
    Returns the font metrics for a given font.
 public boolean isDrawingBuffer() 
    isDrawingBuffer
 public static PrintStream logStream() 
    logStream
 public  void setClip(Shape shape) 
    Sets the current clipping region
 public  void setClip(int x,
    int y,
    int width,
    int height) 
    Sets the clipping region.
 public  void setColor(Color color) 
    Sets the color to draw stuff with.
 public  void setDebugOptions(int options) 
    setDebugOptions
 public static  void setFlashColor(Color color) 
    setFlashColor
 public static  void setFlashCount(int count) 
    setFlashCount
 public static  void setFlashTime(int time) 
    setFlashTime
 public  void setFont(Font font) 
    setFont
 public static  void setLogStream(PrintStream stream) 
    setLogStream
 public  void setPaintMode() 
    setPaintMode
 public  void setXORMode(Color color) 
    setXORMode
 public  void translate(int x,
    int y) 
    translate