| Overview | Package | Class | Tree | Index | Help | NetCharts Pro (Applets) 7.0 | ||
| PREV CLASS | NEXT CLASS | FRAMES | NO FRAMES | ||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||
java.lang.Object | +--netcharts.graphics.NFRegion
Within an HTML file, the following parameters (as supported by NFParam) can be used to specify the attributes of a label:
BorderType - Any of the following keywords:
BorderWidth - Numeric border width (in pixels) (default 4)
Image - URL for image file to be used as background
| Field Summary | |
| static int | BOX
Box border |
| static int | ETCHED
Deprecated. Etched border |
| static int | NONE
No border |
| static int | RAISED
Raised border |
| static int | RECESS
Recessed border |
| static int | SHADOW
Shadow border |
| static int | SIZE
Size image to fit area |
| static int | TILE
Tile image in area |
| Constructor Summary | |
| NFRegion()
Create a new region, using all defaults. | |
| NFRegion(java.awt.Graphics g)
Create a new region, using default attributes and position. | |
| NFRegion(java.awt.Graphics g,
int x,
int y,
int width,
int height)
Create a new region, using default attributes. | |
| NFRegion(java.awt.Graphics g,
int x,
int y,
int width,
int height,
java.awt.Color color,
int borderType,
int borderWidth,
java.awt.Color borderColor)
Create a new region, specifying all attributes. | |
| NFRegion(NFRegion region)
Create a new region, specifying all attributes. | |
| Method Summary | |
| void | draw()
Draw a region using the current attributes. |
| void | draw(java.awt.Graphics g)
Draw a region in the given graphics context, using the current attributes. |
| void | draw(java.awt.Graphics g,
int x,
int y)
Draw a region at the given location, using the current attributes. |
| void | draw(java.awt.Graphics g,
int x,
int y,
int width,
int height)
Draw a region at the given location and size, using the current attributes. |
| void | draw(java.awt.Graphics g,
int x,
int y,
int width,
int height,
java.awt.Color color,
int borderType,
int borderWidth,
java.awt.Color borderColor,
java.awt.Image im)
Draw a region at the given location and size, using the current attributes. |
| static void | draw(java.awt.Graphics g,
int x,
int y,
int width,
int height,
java.awt.Color color,
int borderType,
int borderWidth,
java.awt.Color borderColor,
java.awt.Image im,
int imageType)
Draw a region given all of the attributes, using a scale factor of 0. |
| static void | draw(java.awt.Graphics g,
int x,
int y,
int width,
int height,
java.awt.Color color,
int borderType,
int borderWidth,
java.awt.Color borderColor,
java.awt.Image im,
int imageType,
double scale)
Draw a region given all of the attributes. |
| static void | draw(java.awt.Graphics g,
int x,
int y,
int width,
int height,
java.awt.Color color,
int borderType,
int borderWidth,
java.awt.Color borderColor,
java.awt.Image im,
int imageType,
double scale,
java.lang.String label,
int justify,
int labelMargin,
java.awt.Font labelFont,
java.awt.Color labelColor)
Draw a region given all of the attributes. |
| NFRegionBorder | getBorder()
Get the amount of space used by the border on all four sides of the region, based on the current border style and width. |
| static NFRegionBorder | getBorder(int borderType,
int borderWidth)
Get the amount of space used by the border on all four sides of the region, based on the given border style and width. |
| static NFRegionBorder | getBorder(int borderType,
int borderWidth,
NFRegionBorder b,
double scale)
Get the amount of space used by the border on all four sides of the region, based on the given border style and width. |
| static NFRegionBorder | getBorder(int borderType,
int borderWidth,
NFRegionBorder b,
double scale,
java.lang.String label,
java.awt.Font labelFont)
Get the amount of space used by the border on all four sides of the region, based on the given border style and width. |
| static NFRegionBorder | getBorder(int borderType,
int borderWidth,
java.lang.String label,
java.awt.Font labelFont)
Get the amount of space used by the border on all four sides of the region, based on the given border style and width. |
| static NFRegionBorder | getBorder(int borderType,
int borderWidth,
java.lang.String label,
java.awt.Font labelFont,
NFRegionBorder b)
Get the amount of space used by the border on all four sides of the region, based on the given border style and width. |
| NFRegionBorder | getBorder(NFRegionBorder b)
Get the amount of space used by the border on all four sides of the region, based on the current border style and width. |
| java.awt.Color | getBorderColor()
Get the border color. |
| int | getBorderType()
Returns the current border type |
| int | getBorderWidth()
Returns the current border type |
| java.awt.Color | getColor()
Get the color. |
| void | getHashID(java.lang.StringBuffer buf)
Appends a string that represents the value of all key properties to the given buffer |
| java.awt.Image | getImage()
Return the currently assigned image or null |
| int | getImageType()
Get the image type |
| java.lang.String | getLabel()
Get the label of this region. |
| java.awt.Color | getLabelColor()
Get the color of the label. |
| java.awt.Font | getLabelFont()
Get the label font. |
| static NFRegion | loadParams(NFParam p,
java.lang.Object val)
Build a new region, given a vector of values from the parser. |
| static NFRegion | loadParams(NFParam p,
java.lang.Object val,
int offset)
Build a new region, given a vector of values from the parser, starting at the given offset. |
| static void | loadParams(NFRegion region,
java.util.Vector v,
int offset)
Load the given region using the values in the given vector starting at the given offset. |
| void | setBorder(int type)
Set the border type. |
| void | setBorder(int type,
int width,
java.awt.Color color)
Set the border attributes. |
| void | setBorderColor(java.awt.Color color)
Set the border color. |
| void | setBorderCornerStyle(int topLeftCornerType,
int topRightCornerType,
int bottomRightCornerType,
int bottomLeftCornerType)
Set the border corner attributes. |
| void | setBorderType(int type)
Set the border type. |
| void | setBorderWidth(int width)
Set the border width. |
| void | setColor(java.awt.Color color)
Set the color. |
| void | setCornerOverhangColor(java.awt.Color color)
Set the corner overhang color. |
| void | setGraphics(java.awt.Graphics g)
Set the graphics context. |
| void | setImage(java.awt.Image im)
Set the background image. |
| void | setImageType(int type)
Set the image type |
| void | setJustify(int justify)
Set the justification of the Region label. |
| void | setLabel(java.lang.String label)
Set the text of the label. |
| void | setLabelColor(java.awt.Color labelColor)
Set the color of the label. |
| void | setLabelFont(java.awt.Font labelFont)
Set the font of the label. |
| void | setLabelMargin(int width)
Set the margin used in right and left justification of the Region label. |
| void | setPos(int x,
int y)
Set the upper left position for the region. |
| void | setScale(double scale)
Set the scale factor for this region |
| void | setSize(int width,
int height)
Set the size of the region. |
| Field Detail |
public static final int NONE
public static final int BOX
public static final int SHADOW
public static final int RAISED
public static final int RECESS
public static final int ETCHED
public static final int TILE
public static final int SIZE
| Constructor Detail |
public NFRegion(java.awt.Graphics g,
int x,
int y,
int width,
int height,
java.awt.Color color,
int borderType,
int borderWidth,
java.awt.Color borderColor)
g
- The Graphics to draw on.
x
- The X coordinate of the Region.
y
- The Y coordinate of the Region.
width
- The width of the Region.
height
- The height of the Region.
color
- The background color.
borderType
- The border type.
borderWidth
- The border width.
borderColor
- The border color.
public NFRegion(java.awt.Graphics g,
int x,
int y,
int width,
int height)
g
- The Graphics to draw on.
x
- The X coordinate of the Region.
y
- The Y coordinate of the Region.
width
- The width of the Region.
height
- The height of the Region.public NFRegion(java.awt.Graphics g)
g
- The Graphics to draw on.public NFRegion()
public NFRegion(NFRegion region)
region
- The Region to copy attributes from.| Method Detail |
public void setLabelMargin(int width)
width
- The new label margin.public void setJustify(int justify)
justify
- The justification.public java.awt.Color getLabelColor()
public void setLabelColor(java.awt.Color labelColor)
labelColor
- The label color.public java.lang.String getLabel()
public void setLabel(java.lang.String label)
label
- The label text.public java.awt.Font getLabelFont()
public void setLabelFont(java.awt.Font labelFont)
labelFont
- The label font.
public static NFRegion loadParams(NFParam p,
java.lang.Object val)
p
- The NFParam object to load parameters from.
val
- The value of the parameter to load.
public static NFRegion loadParams(NFParam p,
java.lang.Object val,
int offset)
p
- The NFParam object to load parameters from.
val
- The value of the parameter to load.
offset
- The offset of the region parameters in the given value.
public static void loadParams(NFRegion region,
java.util.Vector v,
int offset)
region
- The NFRegion to modify.
v
- The value of the parameter to load.
offset
- The offset of the region parameters in the given value.public void setGraphics(java.awt.Graphics g)
g
- The Graphics.public void setImage(java.awt.Image im)
im
- The background Image.public java.awt.Image getImage()
public void setCornerOverhangColor(java.awt.Color color)
color
- The corner overhang background color.public void setColor(java.awt.Color color)
color
- The background color.public java.awt.Color getColor()
public void setPos(int x,
int y)
x
- The X coordinate of the region.
y
- The Y coordinate of the region.
public void setSize(int width,
int height)
width
- The width of the region.
height
- The height of the region.public void setBorder(int type)
type
- The border type.
public void setBorderCornerStyle(int topLeftCornerType,
int topRightCornerType,
int bottomRightCornerType,
int bottomLeftCornerType)
topLeftCornerType
- The top left corner type.
topRightCornerType
- The top right corner type.
bottomRightCornerType
- The bottom right corner type.
bottomLeftCornerType
- The bottom left corner type.
public void setBorder(int type,
int width,
java.awt.Color color)
type
- The border type.
width
- The border width.
color
- The border color.public void setBorderColor(java.awt.Color color)
color
- The border color.public void setScale(double scale)
scale
- The scale factor.public java.awt.Color getBorderColor()
public void setBorderType(int type)
type
- The border type.public void setBorderWidth(int width)
width
- The border width.public void setImageType(int type)
type
- The image type.public int getImageType()
public int getBorderWidth()
public int getBorderType()
public NFRegionBorder getBorder()
public NFRegionBorder getBorder(NFRegionBorder b)
If the given object is non-null, the values will be returned in it, otherwise a new object will be created.
b
- Where to store the border.
public static NFRegionBorder getBorder(int borderType,
int borderWidth)
borderType
- The border type.
borderWidth
- The border width.
public static NFRegionBorder getBorder(int borderType,
int borderWidth,
java.lang.String label,
java.awt.Font labelFont)
borderType
- The border type.
borderWidth
- The border width.
label
- The region label.
labelFont
- The region label font.
public static NFRegionBorder getBorder(int borderType,
int borderWidth,
java.lang.String label,
java.awt.Font labelFont,
NFRegionBorder b)
If the given object is non-null, the values will be returned in it, otherwise a new object will be created.
borderType
- The border type.
borderWidth
- The border width.
label
- The region label.
labelFont
- The region label font.
b
- Where to store the border.
public static NFRegionBorder getBorder(int borderType,
int borderWidth,
NFRegionBorder b,
double scale)
If the given object is non-null, the values will be returned in it, otherwise a new object will be created.
borderType
- The border type.
borderWidth
- The border width.
b
- Where to store the border.
scale
- The scale factor.
public static NFRegionBorder getBorder(int borderType,
int borderWidth,
NFRegionBorder b,
double scale,
java.lang.String label,
java.awt.Font labelFont)
If the given object is non-null, the values will be returned in it, otherwise a new object will be created.
borderType
- The border type.
borderWidth
- The border width.
b
- Where to store the border.
scale
- The scale factor.
label
- The region label.
labelFont
- The region label font.public void getHashID(java.lang.StringBuffer buf)
buf
- The buffer to append the hash id to.public void draw()
public void draw(java.awt.Graphics g)
g
- The Graphics.
public void draw(java.awt.Graphics g,
int x,
int y)
g
- The Graphics.
x
- The X coordinate of the region.
y
- The Y coordinate of the region.
public void draw(java.awt.Graphics g,
int x,
int y,
int width,
int height)
g
- The Graphics.
x
- The X coordinate of the region.
y
- The Y coordinate of the region.
width
- The width of the region.
height
- The height of the region.
public void draw(java.awt.Graphics g,
int x,
int y,
int width,
int height,
java.awt.Color color,
int borderType,
int borderWidth,
java.awt.Color borderColor,
java.awt.Image im)
g
- The Graphics.
x
- The X coordinate of the region.
y
- The Y coordinate of the region.
width
- The width of the region.
height
- The height of the region.
color
- The background color.
borderType
- The border type.
borderWidth
- The border width.
borderColor
- The border color.
im
- The background Image.
public static void draw(java.awt.Graphics g,
int x,
int y,
int width,
int height,
java.awt.Color color,
int borderType,
int borderWidth,
java.awt.Color borderColor,
java.awt.Image im,
int imageType)
g
- The Graphics.
x
- The X coordinate of the region.
y
- The Y coordinate of the region.
width
- The width of the region.
height
- The height of the region.
color
- The background color.
borderType
- The border type.
borderWidth
- The border width.
borderColor
- The border color.
im
- The background Image.
imageType
- The image type.
public static void draw(java.awt.Graphics g,
int x,
int y,
int width,
int height,
java.awt.Color color,
int borderType,
int borderWidth,
java.awt.Color borderColor,
java.awt.Image im,
int imageType,
double scale)
g
- The Graphics.
x
- The X coordinate of the region.
y
- The Y coordinate of the region.
width
- The width of the region.
height
- The height of the region.
color
- The background color.
borderType
- The border type.
borderWidth
- The border width.
borderColor
- The border color.
im
- The background Image.
imageType
- The image type.
scale
- The scale factor.
public static void draw(java.awt.Graphics g,
int x,
int y,
int width,
int height,
java.awt.Color color,
int borderType,
int borderWidth,
java.awt.Color borderColor,
java.awt.Image im,
int imageType,
double scale,
java.lang.String label,
int justify,
int labelMargin,
java.awt.Font labelFont,
java.awt.Color labelColor)
g
- The Graphics.
x
- The X coordinate of the region.
y
- The Y coordinate of the region.
width
- The width of the region.
height
- The height of the region.
color
- The background color.
borderType
- The border type.
borderWidth
- The border width.
borderColor
- The border color.
im
- The background Image.
imageType
- The image type.
scale
- The scale factor.
label
- The region label.
justify
- The region label justification.
labelMargin
- The region label margin.
labelFont
- The region label font.
labelColor
- The label color.| Overview | Package | Class | Tree | Index | Help | |||
| PREV CLASS | NEXT CLASS | FRAMES | NO FRAMES | ||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||
| Visual Mining, Inc. | Copyright © Visual Mining, Inc. 1996 - 2010 |
Last Modified: Jun 29, 2010 |