Modifier and Type | Class and Description |
---|---|
public static enum | Paint9Painter.
Enumeration for the types of painting this class can handle. |
Modifier and Type | Field and Description |
---|---|
private static final Insets | |
public static final int | PAINT_ALL
Specifies that all regions should be painted. |
public static final int | |
public static final int | |
public static final int | |
public static final int | |
public static final int | |
public static final int | |
public static final int | |
public static final int | |
public static final int |
Access | Constructor and Description |
---|---|
public |
Modifier and Type | Method and Description |
---|---|
protected Image | createImage(Component
Component painting to c, int Width of image to create w, int Height to image to create h, GraphicsConfiguration GraphicsConfiguration that will be
rendered to, this may be null. config, Object[] Arguments passed to paint args)Overrides sun. Subclassed to always create a translucent image. |
private void | drawChunk(Image
Image to render. image, Graphics Graphics to render to g, boolean Whether the image should be stretched or timed in the
provided space. stretch, int X origin to draw to dx1, int Y origin to draw to dy1, int End x location to draw to dx2, int End y location to draw to dy2, int X origin to draw from sx1, int Y origin to draw from sy1, int Max x location to draw from sx2, int Max y location to draw from sy2, boolean Used if the image is not stretched. If true it
indicates the image should be tiled along the x axis. xDirection)Draws a portion of an image, stretched or tiled. |
private void | |
public void | paint(Component
Component rendering to c, Graphics Graphics to render to g, int X-coordinate x, int Y-coordinate y, int Width to render to w, int Height to render to h, Image Image to render from, if source, Insets null this method
will do nothingInsets specifying the portion of the image that
will be stretched or tiled, if sInsets, Insets null empty
Insets will be used.Destination insets specifying the portion of the image
will be stretched or tiled, if dInsets, Paint9Painter.null empty
Insets will be used.Specifies what type of algorithm to use in painting type,Specifies portion of image to render, if
mask)PAINT_ALL is specified, any other regions
specified will not be painted, for example
PAINT_ALL | PAINT_CENTER paints everything but the center.Paints using the algorithm specified by |
protected void | |
protected void | paintToImage(Component
Component painting to, may be null. c, Image Image to paint to destImage, Graphics Graphics to paint to, obtained from the passed in Image. g, int Width to paint to w, int Height to paint to h, Object[] Arguments supplied to args)paint Implements abstract sun. Paints the representation to cache to the supplied Graphics. |
public static boolean | Returns: true ifimage is non-null and has a positive
size.Image to check. image)Convenience method for testing the validity of an image. |
EMPTY_INSETS | back to summary |
---|---|
private static final Insets EMPTY_INSETS |
PAINT_ALL | back to summary |
---|---|
public static final int PAINT_ALL Specifies that all regions should be painted. If this is set any other regions specified will not be painted. For example PAINT_ALL | PAINT_CENTER will paint all but the center. |
PAINT_BOTTOM | back to summary |
---|---|
public static final int PAINT_BOTTOM |
PAINT_BOTTOM_LEFT | back to summary |
---|---|
public static final int PAINT_BOTTOM_LEFT |
PAINT_BOTTOM_RIGHT | back to summary |
---|---|
public static final int PAINT_BOTTOM_RIGHT |
PAINT_CENTER | back to summary |
---|---|
public static final int PAINT_CENTER |
PAINT_LEFT | back to summary |
---|---|
public static final int PAINT_LEFT |
PAINT_RIGHT | back to summary |
---|---|
public static final int PAINT_RIGHT |
PAINT_TOP | back to summary |
---|---|
public static final int PAINT_TOP |
PAINT_TOP_LEFT | back to summary |
---|---|
public static final int PAINT_TOP_LEFT |
PAINT_TOP_RIGHT | back to summary |
---|---|
public static final int PAINT_TOP_RIGHT |
Paint9Painter | back to summary |
---|---|
public Paint9Painter(int cacheCount) |
createImage | back to summary |
---|---|
protected Image createImage(Component c, int w, int h, GraphicsConfiguration config, Object[] args) Overrides sun. Subclassed to always create a translucent image.
|
drawChunk | back to summary |
---|---|
private void drawChunk(Image image, Graphics g, boolean stretch, int dx1, int dy1, int dx2, int dy2, int sx1, int sy1, int sx2, int sy2, boolean xDirection) Draws a portion of an image, stretched or tiled.
|
drawImage | back to summary |
---|---|
private void drawImage(Image image, Graphics g, int dx1, int dy1, int dx2, int dy2, int sx1, int sy1, int sx2, int sy2) |
paint | back to summary |
---|---|
public void paint(Component c, Graphics g, int x, int y, int w, int h, Image source, Insets sInsets, Insets dInsets, Paint9Painter. Paints using the algorithm specified by
|
paint9 | back to summary |
---|---|
protected void paint9(Graphics g, int x, int y, int w, int h, Image image, Insets sInsets, Insets dInsets, Paint9Painter. |
paintToImage | back to summary |
---|---|
protected void paintToImage(Component c, Image destImage, Graphics g, int w, int h, Object[] args) Implements abstract sun. Doc from sun. Paints the representation to cache to the supplied Graphics. |
validImage | back to summary |
---|---|
public static boolean validImage(Image image) Convenience method for testing the validity of an image.
|
Modifier and Type | Field and Description |
---|---|
public static final Paint9Painter. | CENTER
Painting type indicating the image should be centered in the space provided. |
public static final Paint9Painter. | PAINT9_STRETCH
Painting type indicating the image should be split into nine regions with the top, left, bottom and right areas stretched. |
public static final Paint9Painter. | PAINT9_TILE
Painting type indicating the image should be split into nine regions with the top, left, bottom and right areas tiled. |
public static final Paint9Painter. | TILE
Painting type indicating the image should be tiled across the specified width and height. |
Access | Constructor and Description |
---|---|
private |
Modifier and Type | Method and Description |
---|---|
public static Paint9Painter. | |
public static Paint9Painter. |
CENTER | back to summary |
---|---|
public static final Paint9Painter. Painting type indicating the image should be centered in
the space provided. When used the |
PAINT9_STRETCH | back to summary |
---|---|
public static final Paint9Painter. Painting type indicating the image should be split into nine regions with the top, left, bottom and right areas stretched. |
PAINT9_TILE | back to summary |
---|---|
public static final Paint9Painter. Painting type indicating the image should be split into nine regions with the top, left, bottom and right areas tiled. |
TILE | back to summary |
---|---|
public static final Paint9Painter. Painting type indicating the image should be tiled across the
specified width and height. When used the |
PaintType | back to summary |
---|---|
private PaintType() |
valueOf | back to summary |
---|---|
public static Paint9Painter. |
values | back to summary |
---|---|
public static Paint9Painter. |