lt.monarch.chart.chart2D
Class MarkerLine

java.lang.Object
  extended by lt.monarch.chart.engine.AbstractChartObject<MarkerPaintTags>
      extended by lt.monarch.chart.AbstractChartMarker
          extended by lt.monarch.chart.chart2D.MarkerLine
All Implemented Interfaces:
java.io.Serializable, ChartObject, StyleEditorEntity
Direct Known Subclasses:
HorizontalMarkerLine, VerticalMarkerLine

public abstract class MarkerLine
extends AbstractChartMarker

Draws a line with a label.

See Also:
Serialized Form

Field Summary
Modifier and Type Field and Description
protected  java.lang.Object level
          Specifies marker line position on some axis
protected  PlaneMapper mapper
          Mapper, used to map output to a plane in a n-dimensional space
 
Fields inherited from class lt.monarch.chart.AbstractChartMarker
axisMapper, label, textStyle
 
Fields inherited from class lt.monarch.chart.engine.AbstractChartObject
AXIS_SORT_POSITION, BREAK_LINE_POSITION, DEFAULT_SORT_POSITION, GRID_SORT_POSITION, MARKER_SERIES_SORT_POSITION, MARKERS_SORT_POSITION, paintStyle, SERIES_SORT_POSITION, sortPosition, style
 
Constructor Summary
Constructor and Description
MarkerLine(PlaneMapper mapper, AxisMapper axisMapper)
          Constructs a new MarkerLine with the specified plane and axis mappers.
 
Method Summary
Modifier and Type Method and Description
 java.lang.Object getLevel()
          Gets the level where the marker line is mapped
 int getSortPosition()
          Returns chart object paint order index.
 void setLabelPosition(double position, Alignment align)
          Sets the alignment and position of the label.
 void setLabelPosition(double position, Alignment align, Orientation orientation)
          Sets the position, alignment and orientation of the label.
 void setLevel(java.lang.Object level)
          Sets the marker line position.
 
Methods inherited from class lt.monarch.chart.AbstractChartMarker
getAxisMapper, getLabel, getPaintMode, getParent, getStyle, getTextStyle, isLabelEmpty, setLabel, setPaintMode
 
Methods inherited from class lt.monarch.chart.engine.AbstractChartObject
activate, chart, copy, deactivate, dispose, finalize, getChart, getChartObjectBounds, getPaintStyle, getStyle, invalidate, isVisible, layout, repaint, repaint, setChart, setVisible
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface lt.monarch.chart.engine.ChartObject
draw
 

Field Detail

mapper

protected final PlaneMapper mapper
Mapper, used to map output to a plane in a n-dimensional space


level

protected java.lang.Object level
Specifies marker line position on some axis

Constructor Detail

MarkerLine

public MarkerLine(PlaneMapper mapper,
                  AxisMapper axisMapper)
Constructs a new MarkerLine with the specified plane and axis mappers.

Parameters:
mapper - the plane mapper
axisMapper - the axis mapper
Method Detail

setLabelPosition

public void setLabelPosition(double position,
                             Alignment align)
Sets the alignment and position of the label.

Parameters:
position - label position on the line in range 0..1
align - label alignment: below-of/left-of or on-top-of/right-of the line

setLabelPosition

public void setLabelPosition(double position,
                             Alignment align,
                             Orientation orientation)
Sets the position, alignment and orientation of the label.

Parameters:
position - label position on the line in range 0..1
align - label alignment: below-of/left-of or on-top-of/right-of the line
orientation - label orientation: vertical or horizontal

setLevel

public void setLevel(java.lang.Object level)
Sets the marker line position.

Parameters:
level - line position in AxisMapper coordinates

getLevel

public java.lang.Object getLevel()
Gets the level where the marker line is mapped

Returns:
Returns the level how the marker line is elevated or shifted on the axis.

getSortPosition

public int getSortPosition()
Description copied from interface: ChartObject
Returns chart object paint order index.

Specified by:
getSortPosition in interface ChartObject
Overrides:
getSortPosition in class AbstractChartMarker
Returns:
object paint order index