|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jfree.chart.annotations.TextAnnotation
org.jfree.chart.annotations.XYTextAnnotation
A text annotation that can be placed at a particular (x, y) location on an XYPlot.
| Field Summary |
| Fields inherited from class org.jfree.chart.annotations.TextAnnotation |
DEFAULT_FONT, DEFAULT_PAINT, DEFAULT_ROTATION_ANCHOR, DEFAULT_ROTATION_ANGLE, DEFAULT_TEXT_ANCHOR |
| Constructor Summary | |
XYTextAnnotation(java.lang.String text,
double x,
double y)
Creates a new annotation to be displayed at the given coordinates. |
|
| Method Summary | |
java.lang.Object |
clone()
Returns a clone of the annotation. |
void |
draw(java.awt.Graphics2D g2,
XYPlot plot,
java.awt.geom.Rectangle2D dataArea,
ValueAxis domainAxis,
ValueAxis rangeAxis)
Draws the annotation. |
double |
getX()
Returns the x coordinate for the text anchor point (measured against the domain axis). |
double |
getY()
Returns the y coordinate for the text anchor point (measured against the range axis). |
void |
setX(double x)
Sets the x coordinate for the text anchor point (measured against the domain axis). |
void |
setY(double y)
Sets the y coordinate for the text anchor point (measured against the range axis). |
| Methods inherited from class org.jfree.chart.annotations.TextAnnotation |
equals, getFont, getPaint, getRotationAnchor, getRotationAngle, getText, getTextAnchor, setFont, setPaint, setRotationAnchor, setRotationAngle, setText, setTextAnchor |
| Methods inherited from class java.lang.Object |
finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public XYTextAnnotation(java.lang.String text,
double x,
double y)
text - the text.x - the x-coordinate.y - the y-coordinate.| Method Detail |
public double getX()
public void setX(double x)
x - the x coordinate.public double getY()
public void setY(double y)
y - the y coordinate.
public void draw(java.awt.Graphics2D g2,
XYPlot plot,
java.awt.geom.Rectangle2D dataArea,
ValueAxis domainAxis,
ValueAxis rangeAxis)
draw in interface XYAnnotationg2 - the graphics device.plot - the plot.dataArea - the data area.domainAxis - the domain axis.rangeAxis - the range axis.
public java.lang.Object clone()
throws java.lang.CloneNotSupportedException
java.lang.CloneNotSupportedException - if the annotation can't be cloned.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||