|
ChartCat 1.2 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectli.netcat.chart.util.tag.BasicTagManager
Basic implementation of a TagManager
. This manager does not use any line to
connect the text with the target point. It also does not handle overlaps of tags.
The text alignment and the angle can be specified.
Field Summary | |
static int |
BASELINE
Equal to ChartConstants.BASELINE |
static int |
BOTTOM
Equal to ChartConstants.BOTTOM |
static int |
CENTER
Equal to ChartConstants.CENTER |
static int |
LEFT
Equal to ChartConstants.LEFT |
static int |
RIGHT
Equal to ChartConstants.RIGHT |
static int |
TOP
Equal to ChartConstants.TOP |
Constructor Summary | |
BasicTagManager()
Constructs a new BasicTagManager with its default properties. |
|
BasicTagManager(int horizontalTextAlignment,
int verticalTextAlignment,
float angleDegrees)
Constructs a new BasicTagManager using the given text alignment and angle. |
Method Summary | |
float |
getAngleDegrees()
Returns the angle in degrees. |
int |
getHorizontalTextAlignment()
Returns the horizontal text alignment. |
Layout |
getLayout(TagPart tagPart,
java.awt.Graphics g)
Handles overlaps of the given labels and calculates the resulting layout. |
int |
getVerticalTextAlignment()
Returns the vertical text alignment. |
void |
setAngleDegrees(float angleDegrees)
Sets the angle in degrees. |
void |
setHorizontalTextAlignment(int horizontalTextAlignment)
Sets the horizontal text alignment. |
void |
setVerticalTextAlignment(int verticalTextAlignment)
Sets the vertical text alignment. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int TOP
ChartConstants.TOP
public static final int LEFT
ChartConstants.LEFT
public static final int BOTTOM
ChartConstants.BOTTOM
public static final int RIGHT
ChartConstants.RIGHT
public static final int CENTER
ChartConstants.CENTER
public static final int BASELINE
ChartConstants.BASELINE
Constructor Detail |
public BasicTagManager()
BasicTagManager
with its default properties.
public BasicTagManager(int horizontalTextAlignment, int verticalTextAlignment, float angleDegrees)
BasicTagManager
using the given text alignment and angle.
horizontalTextAlignment
- Specify one of LEFT
, CENTER
or RIGHT
.verticalTextAlignment
- Specify one of TOP
, CENTER
, BASELINE
or BOTTOM
.angleDegrees
- The angle in degrees. Horizontal is specified with 0.0f and vertical with 90.0f (turn anticlockwise).Method Detail |
public int getHorizontalTextAlignment()
LEFT
, CENTER
or RIGHT
.public void setHorizontalTextAlignment(int horizontalTextAlignment)
horizontalTextAlignment
- Specify one of LEFT
, CENTER
or RIGHT
.public int getVerticalTextAlignment()
TOP
, CENTER
, BASELINE
or BOTTOM
.public void setVerticalTextAlignment(int verticalTextAlignment)
verticalTextAlignment
- Specify one of TOP
, CENTER
, BASELINE
or BOTTOM
.public float getAngleDegrees()
public void setAngleDegrees(float angleDegrees)
public Layout getLayout(TagPart tagPart, java.awt.Graphics g)
TagManager
getLayout
in interface TagManager
tagPart
- The tag part that havs to be layouted, never null
.
|
ChartCat 1.2 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |