|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.dmonix.util.image.imageobjects.BaseImageObject
The base class for all types of image objects.
Copyright: Copyright (c) 2003
Company: dmonix.org
| Field Summary | |
protected static java.awt.Color |
bg
The background color. |
protected static float[] |
dash1
|
protected static java.awt.Color |
fg
The foreground color. |
protected int |
HEIGHT
The height of the image. |
protected int |
NOTCH_LENGTH
The size/length of the notch used on either axis. |
protected static java.awt.BasicStroke |
stroke
|
protected static java.awt.BasicStroke |
STROKE_DASHED_LINE
|
protected static java.awt.BasicStroke |
STROKE_DOTTED_LINE
|
protected static java.awt.BasicStroke |
STROKE_LINE
|
protected static java.awt.BasicStroke |
STROKE_LINE_THICKER
|
protected static java.awt.BasicStroke |
STROKE_POINT
|
protected static java.awt.BasicStroke |
wideStroke
|
protected int |
WIDTH
The width of the image. |
protected int |
X_AXIS_ABSOLUTE_LENGTH
The absolute length of the X-axis. |
protected int |
X_AXIS_HORIZONTAL_END_OFFSET
The distance from the X-axis line to the right of the image. |
protected int |
X_AXIS_HORIZONTAL_START_OFFSET
The distance from the X-axis line to the left of the image. |
protected int |
X_AXIS_NOTCH_COUNT
The number of notches on the x-axis. |
protected double |
X_AXIS_NOTCH_DISTANCE
The distance between the notches on the x-axis. |
protected double |
X_AXIS_SCALE_FACTOR
The scale factor for the X-axis. |
protected int |
X_AXIS_SCALE_STEP
The step size for the X-axis . |
protected int |
X_AXIS_VERTICAL_OFFSET
The distance from the X-axis line to the bottom of the image. |
protected int |
Y_AXIS_ABSOLUTE_LENGTH
The absolute length of the Y-axis . |
protected int |
Y_AXIS_HORIZONTAL_OFFSET
The distance from the Y-axis line to the left of the image. |
protected int |
Y_AXIS_NOTCH_COUNT
The number of notches on the y-axis. |
protected double |
Y_AXIS_NOTCH_DISTANCE
The distance between the notches on the y-axis. |
protected double |
Y_AXIS_SCALE_FACTOR
The scale factor for the Y-axis. |
protected int |
Y_AXIS_SCALE_STEP
The step size for the Y-axis . |
protected int |
Y_AXIS_VERTICAL_END_OFFSET
The distance from the Y-axis line to the bottom of the image. |
protected int |
Y_AXIS_VERTICAL_START_OFFSET
The distance from the Y-axis line to the top of the image. |
| Constructor Summary | |
BaseImageObject(int width,
int height)
Constructor [obviously]. |
|
| Method Summary | |
protected void |
calculateXAxisNotchDistanceBasedOnObjects(int objects)
Calculate and set the distance between the X-axis notches. |
protected void |
calculateXAxisNotchDistanceBasedOnValue(int maxHeight)
|
protected void |
calculateYAxisNotchDistanceBasedOnObjects(int objects)
|
protected void |
calculateYAxisNotchDistanceBasedOnValue(int maxHeight)
Calculate and set the distance between the Y-axis notches. |
protected void |
drawXAxis(java.awt.Graphics2D g2,
boolean notches,
boolean numbering,
boolean scale)
Draw the X-axis line. |
protected void |
drawYAxis(java.awt.Graphics2D g2,
boolean notches,
boolean numbering,
boolean scale)
Draw the Y-axis line. |
java.awt.Rectangle |
getBounds()
Get the rectangle for this image. |
abstract void |
paint(java.awt.Graphics2D g2)
Paint the image. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected int X_AXIS_HORIZONTAL_START_OFFSET
protected int X_AXIS_HORIZONTAL_END_OFFSET
protected int X_AXIS_VERTICAL_OFFSET
protected int X_AXIS_ABSOLUTE_LENGTH
protected double X_AXIS_SCALE_FACTOR
protected final int X_AXIS_SCALE_STEP
protected int Y_AXIS_HORIZONTAL_OFFSET
protected final int Y_AXIS_VERTICAL_START_OFFSET
protected final int Y_AXIS_VERTICAL_END_OFFSET
protected final int Y_AXIS_SCALE_STEP
protected int Y_AXIS_ABSOLUTE_LENGTH
protected final int NOTCH_LENGTH
protected static final java.awt.Color bg
protected static final java.awt.Color fg
protected static final java.awt.BasicStroke stroke
protected static final java.awt.BasicStroke STROKE_POINT
protected static final java.awt.BasicStroke STROKE_DOTTED_LINE
protected static final java.awt.BasicStroke STROKE_LINE
protected static final java.awt.BasicStroke STROKE_LINE_THICKER
protected static final java.awt.BasicStroke wideStroke
protected static final float[] dash1
protected static final java.awt.BasicStroke STROKE_DASHED_LINE
protected int WIDTH
protected int HEIGHT
protected double X_AXIS_NOTCH_DISTANCE
protected double Y_AXIS_NOTCH_DISTANCE
protected int X_AXIS_NOTCH_COUNT
protected int Y_AXIS_NOTCH_COUNT
protected double Y_AXIS_SCALE_FACTOR
| Constructor Detail |
public BaseImageObject(int width,
int height)
width - The width of the imageheight - The height of the image| Method Detail |
public java.awt.Rectangle getBounds()
getBounds in interface ImageObjectpublic abstract void paint(java.awt.Graphics2D g2)
paint in interface ImageObjectg2 - The graphics object.protected void calculateXAxisNotchDistanceBasedOnObjects(int objects)
objects - The number of objects to fit on the axis.protected void calculateXAxisNotchDistanceBasedOnValue(int maxHeight)
protected void calculateYAxisNotchDistanceBasedOnObjects(int objects)
protected void calculateYAxisNotchDistanceBasedOnValue(int maxHeight)
maxHeight - The maximum height of the axis.
protected void drawXAxis(java.awt.Graphics2D g2,
boolean notches,
boolean numbering,
boolean scale)
g2 - The graphics objectnotches - Should nothces been drawnnumbering - Should numbering be addedscale - Should a scale be added
protected void drawYAxis(java.awt.Graphics2D g2,
boolean notches,
boolean numbering,
boolean scale)
g2 - The graphics objectnotches - Should notches been drawnnumbering - Should numbering be addedscale - Should a scale be added
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||