public class Annotation extends Tool
Title: Annotation class
Description: Annotation tool.
Copyright (c) 2005-2019 by Steema Software SL. All Rights Reserved.
Company: Steema Software SL
Tool.ToolListener
bBrush, clickTolerance, listenerList, pPen
chart, InternalUse
Constructor and Description |
---|
Annotation() |
Annotation(IBaseChart c) |
Annotation(IBaseChart c,
java.lang.String text) |
Annotation(java.lang.String text) |
Modifier and Type | Method and Description |
---|---|
void |
addToolMouseListener(ToolMouseListener l) |
protected void |
calcTempPosition(int[] xyPosition,
int tmpW,
int tmpH,
int horizMargin,
int vertMargin) |
protected MultiLine |
calcTempWidth(Graphics3D g,
java.lang.String tmp) |
void |
chartEvent(ChartDrawEvent e) |
boolean |
clicked(Point p)
Returns true is point parameter is inside annotation bounds
|
void |
drawText() |
void |
drawText(Graphics3D g) |
AnnotationCallout |
getCallout() |
Cursor |
getCursor()
The Cursor type for when the user moves the mouse over the
Annotation bounds.
|
boolean |
getCustomSize() |
java.lang.String |
getDescription()
Gets descriptive text.
|
int |
getHeight()
Returns the annotation height in pixels
|
protected java.lang.String |
getInnerText() |
int |
getLeft()
The horizontal displacement in pixels of text box from Chart's left
edge.
|
AnnotationPosition |
getPosition()
The default position for the Annotation Tool text box and text.
|
TextShapePosition |
getShape()
The characteristics of the Annotation Tool text and text box Shape.
|
java.lang.String |
getSummary()
Gets detailed descriptive text.
|
java.lang.String |
getText()
The text for the Annotation Tool.
Default value: "" |
StringAlignment |
getTextAlign()
Horizontal alignment of displayed text.
Default value: StringAlignment.Near |
int |
getTop()
The vertical displacement in pixels of text box from Chart's top edge.
|
int |
getWidth()
Returns the annotation width in pixels
|
Cursor |
mouseEvent(FrameworkMouseEvent e,
Cursor c) |
void |
removeToolMouseListener(ToolMouseListener l) |
void |
setChart(IBaseChart c)
Chart associated with this object.
|
void |
setCursor(Cursor value)
Selects the Cursor type for when the user moves the mouse over the
Annotation bounds.
|
void |
setCustomSize(boolean value) |
void |
setHeight(int value)
Sets the annotation height in pixels
|
void |
setLeft(int value)
Sets horizontal displacement in pixels of text box from Chart's left
edge.
|
void |
setPosition(AnnotationPosition value)
Defines a default position for the Annotation Tool text box and text.
|
void |
setText(java.lang.String value)
Defines the text for the Annotation Tool.
Default value: "" |
void |
setTextAlign(StringAlignment value)
Sets the horizontal alignment of displayed text.
Default value: StringAlignment.Near |
void |
setTop(int value)
Sets vertical displacement in pixels of text box from Chart's top edge.
|
void |
setWidth(int value)
Sets the annotation width in pixels
|
addMouseMotionListener, addToolListener, dispose, fireActiveChanged, fireChanged, fireClicked, fireDragged, fireDragging, fireMouse, fireResized, getActive, getBitmapEditor, readResolve, removeMouseMotionListener, removeToolListener, setActive, toString
getChart, invalidate, setBooleanProperty, setColorProperty, setDoubleProperty, setIntegerProperty, setStringProperty
public Annotation()
public Annotation(IBaseChart c)
public Annotation(IBaseChart c, java.lang.String text)
public Annotation(java.lang.String text)
public void addToolMouseListener(ToolMouseListener l)
public void removeToolMouseListener(ToolMouseListener l)
public AnnotationCallout getCallout()
public Cursor getCursor()
public void setCursor(Cursor value)
value
- Cursorpublic void setChart(IBaseChart c)
TeeBase
public StringAlignment getTextAlign()
public void setTextAlign(StringAlignment value)
value
- StringAlignmentpublic int getLeft()
public void setLeft(int value)
value
- intpublic int getTop()
public void setTop(int value)
value
- intpublic AnnotationPosition getPosition()
public void setPosition(AnnotationPosition value)
value
- AnnotationPositionpublic TextShapePosition getShape()
protected java.lang.String getInnerText()
public java.lang.String getText()
public void setText(java.lang.String value)
value
- Stringpublic java.lang.String getDescription()
getDescription
in class Tool
public java.lang.String getSummary()
getSummary
in class Tool
public int getHeight()
public void setHeight(int value)
value
- intpublic int getWidth()
public void setWidth(int value)
value
- intpublic boolean getCustomSize()
public void setCustomSize(boolean value)
protected MultiLine calcTempWidth(Graphics3D g, java.lang.String tmp)
protected void calcTempPosition(int[] xyPosition, int tmpW, int tmpH, int horizMargin, int vertMargin)
public void drawText(Graphics3D g)
public void drawText()
public void chartEvent(ChartDrawEvent e)
chartEvent
in class Tool
public boolean clicked(Point p)
p
- Pointpublic Cursor mouseEvent(FrameworkMouseEvent e, Cursor c)
mouseEvent
in class Tool