|
JMSLTM Numerical Library 6.1 | |||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Objectcom.imsl.chart.AbstractChartNode
com.imsl.chart.ChartNode
com.imsl.chart.Data
com.imsl.chart.Annotation
public class Annotation
Draws an annotation.
Locations are defined in chart (user) coordinates. To convert between
device and user coordinates see Axis.mapDeviceToUser(int, int, double[]) and
Axis.mapUserToDevice(double, double, int[]).
| Field Summary |
|---|
| Fields inherited from class com.imsl.chart.AbstractChartNode |
|---|
AUTOSCALE_DATA, AUTOSCALE_DENSITY, AUTOSCALE_NUMBER, AUTOSCALE_OFF, AUTOSCALE_WINDOW, AXIS_X, AXIS_Y, AXIS_Z, LABEL_TYPE_NONE, LABEL_TYPE_TITLE, LABEL_TYPE_X, LABEL_TYPE_Y, LABEL_TYPE_Z, TRANSFORM_CUSTOM, TRANSFORM_LINEAR, TRANSFORM_LOG |
| Constructor Summary | |
|---|---|
Annotation(ChartNode parent,
Image img,
double x,
double y)
Renders an Image object centered at an x,y location
in chart coordinates. |
|
Annotation(ChartNode parent,
String string,
double x,
double y)
Draws a String at the specific x,y location
in chart coordinates. |
|
Annotation(ChartNode parent,
Text text,
double x,
double y)
Creates a Text object at the specific x,y location
in chart coordinates. |
|
| Method Summary | |
|---|---|
Text |
getText()
Gets the Text for this Annotation object. |
void |
paint(Draw draw)
Paints this node and all of its children. |
void |
setLocation(double x,
double y)
Update the location of this Annotation instance. |
void |
setString(String string)
Sets the String for the Text object to render. |
void |
setText(Text text)
Sets the Text object to render. |
| Methods inherited from class com.imsl.chart.Data |
|---|
dataRange, formatLabel |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public Annotation(ChartNode parent,
Image img,
double x,
double y)
Image object centered at an x,y location
in chart coordinates.
parent - the ChartNode parent of this data node,
usually an Axis objectimg - the Image object to drawx - the x location in user coordinatesy - the y location in user coordinates
public Annotation(ChartNode parent,
String string,
double x,
double y)
String at the specific x,y location
in chart coordinates.
parent - the ChartNode parent of this data node,
usually an Axis objectstring - the String to drawx - the x location in user coordinatesy - the y location in user coordinates
public Annotation(ChartNode parent,
Text text,
double x,
double y)
Text object at the specific x,y location
in chart coordinates.
parent - the ChartNode parent of this data node,
usually an Axis objecttext - the Text object to drawx - the x location in user coordinatesy - the y location in user coordinates| Method Detail |
|---|
public Text getText()
Text for this Annotation object.
public void paint(Draw draw)
paint in class Datadraw - the Draw object to be painted
public void setLocation(double x,
double y)
Annotation instance.
x - a double specifying the new x location in chart
coordinates.y - a double specifying the new y location in chart
coordinates.public void setString(String string)
String for the Text object to render.
string - the new String valuepublic void setText(Text text)
Text object to render.
text - the new Text object
|
JMSLTM Numerical Library 6.1 | |||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||