public class TrackSegment extends ChartAnnotation
COLOR_SELECTED, transform, x, y
propertiesDialog
Constructor and Description |
---|
TrackSegment()
Default ctor
|
TrackSegment(WayPoint wayPoint1,
WayPoint wayPoint2,
PlotWrapper plotWrapper)
Ctor
|
Modifier and Type | Method and Description |
---|---|
void |
addChangeListener(org.jfree.chart.event.AnnotationChangeListener arg0) |
double |
distance(int x,
int y)
Distance to the x/y.
|
void |
draw(java.awt.Graphics2D g2,
org.jfree.chart.plot.XYPlot plot,
java.awt.geom.Rectangle2D dataArea,
org.jfree.chart.axis.ValueAxis domainAxis,
org.jfree.chart.axis.ValueAxis rangeAxis,
int rendererIndex,
org.jfree.chart.plot.PlotRenderingInfo info)
Draws the wayPoint.
|
double |
getCenterValue()
Get the domain value at the center of the segment
|
WayPoint |
getLeft()
Get the left most waypoint.
|
WayPoint |
getRight()
Get the right most waypoint.
|
java.lang.String |
getToolTipText()
Get the tool tip text
|
java.lang.String |
getTypeName()
Type of annotation
|
WayPoint |
getWayPoint1()
Get the WayPoint1 property.
|
WayPoint |
getWayPoint2()
Get the WayPoint2 property.
|
void |
removeChangeListener(org.jfree.chart.event.AnnotationChangeListener arg0) |
void |
setPosition(int x,
int y)
Set the position to the given x/y screen coordinate
|
void |
setWayPoint1(WayPoint value)
Set the WayPoint1 property.
|
void |
setWayPoint2(WayPoint value)
Set the WayPoint2 property.
|
addPropertyChangeListener, applyProperties, distance, doRemove, formatValue, getColor, getName, getPlotWrapper, getPropertiesComponents, getSelected, getX, getY, isActive, removePropertyChangeListener, setActive, setColor, setGraphicsState, setName, setPlotWrapper, setPosition, setSelected, showColorInProperties, toString
doApplyProperties, firePropertyChange, firePropertyChange, getPropertyListeners, getPropertyTabs, isShowing, propertyChange, showProperties, showProperties
applySharableProperties, doShare, doShare, doShareExternal, doShareInternal, getReceiveShareTime, getSharablePropertiesComponent, getShareGroup, getSharing, getUniqueId, initSharable, receiveShareData, removeSharable, setReceiveShareTime, setShareGroup, setSharing, setUniqueId, showSharableDialog
public TrackSegment()
public TrackSegment(WayPoint wayPoint1, WayPoint wayPoint2, PlotWrapper plotWrapper)
wayPoint1
- wayPoint1wayPoint2
- wayPoint1plotWrapper
- The chart I'm inpublic java.lang.String getToolTipText()
getToolTipText
in class ChartAnnotation
public java.lang.String getTypeName()
getTypeName
in class ChartAnnotation
public void setPosition(int x, int y)
setPosition
in class ChartAnnotation
x
- xy
- ypublic double getCenterValue()
public void draw(java.awt.Graphics2D g2, org.jfree.chart.plot.XYPlot plot, java.awt.geom.Rectangle2D dataArea, org.jfree.chart.axis.ValueAxis domainAxis, org.jfree.chart.axis.ValueAxis rangeAxis, int rendererIndex, org.jfree.chart.plot.PlotRenderingInfo info)
g2
- the graphics device.plot
- the plot.dataArea
- the data area.domainAxis
- the domain axis.rangeAxis
- the range axis.rendererIndex
- the renderer index.info
- an optional info object that will be populated with
entity information.public WayPoint getLeft()
public WayPoint getRight()
public void setWayPoint1(WayPoint value)
value
- The new value for WayPoint1public WayPoint getWayPoint1()
public void setWayPoint2(WayPoint value)
value
- The new value for WayPoint2public WayPoint getWayPoint2()
public double distance(int x, int y)
distance
in class ChartAnnotation
x
- mouse xy
- mouse ypublic void addChangeListener(org.jfree.chart.event.AnnotationChangeListener arg0)
public void removeChangeListener(org.jfree.chart.event.AnnotationChangeListener arg0)