lt.monarch.chart.marker
Class BoxMarker

java.lang.Object
  extended by lt.monarch.chart.engine.AbstractChartObject<MarkerTextPaintTags>
      extended by lt.monarch.chart.marker.BoxMarker
All Implemented Interfaces:
java.io.Serializable, ChartObject, StyleEditorEntity

public class BoxMarker
extends AbstractChartObject<MarkerTextPaintTags>

Renders a BoxMarker. BoxMarker is similar to chart itself as it displays chart data, only resized.

See Also:
Serialized Form

Field Summary
Modifier and Type Field and Description
protected  PlaneMapper mapper
           
 Style style
          Local stylesheet.
protected  AxisMapper xMapper
           
protected  java.lang.Object xPos1
           
protected  java.lang.Object xPos2
           
protected  AxisMapper yMapper
           
protected  java.lang.Object yPos1
           
protected  java.lang.Object yPos2
           
 
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
 
Constructor Summary
Constructor and Description
BoxMarker(Axis xAxis, Axis yAxis)
          Constructs a box marker.
BoxMarker(PlaneMapper mapper, AxisMapper xMapper, AxisMapper yMapper)
          Constructs a box marker with given plane mapper and axis mappers.
 
Method Summary
Modifier and Type Method and Description
 void draw(AbstractGraphics g)
          Paints the box marker using current style foreground and background colors.
 PaintStyle<MarkerTextPaintTags> getPaintStyle()
          Gets series paint style object
 Projector getProjector()
          Returns modified projector.
 int getSortPosition()
          Returns chart object paint order index.
 void setBounds(java.lang.Object x1, java.lang.Object y1, java.lang.Object x2, java.lang.Object y2)
          Sets rectangle bounds.
 
Methods inherited from class lt.monarch.chart.engine.AbstractChartObject
activate, chart, copy, deactivate, dispose, finalize, getChart, getChartObjectBounds, getParent, getStyle, 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
 

Field Detail

mapper

protected final PlaneMapper mapper

xMapper

protected final AxisMapper xMapper

yMapper

protected final AxisMapper yMapper

xPos1

protected java.lang.Object xPos1

yPos1

protected java.lang.Object yPos1

xPos2

protected java.lang.Object xPos2

yPos2

protected java.lang.Object yPos2

style

public final Style style
Local stylesheet. All color and font information is stored here

Constructor Detail

BoxMarker

public BoxMarker(Axis xAxis,
                 Axis yAxis)
Constructs a box marker.

Parameters:
xAxis - X axis
yAxis - Y axis

BoxMarker

public BoxMarker(PlaneMapper mapper,
                 AxisMapper xMapper,
                 AxisMapper yMapper)
Constructs a box marker with given plane mapper and axis mappers.

Parameters:
mapper - plane mapper
xMapper - X axis mapper
yMapper - Y axis mapper
Method Detail

getProjector

public Projector getProjector()
Returns modified projector.

Returns:
projector

draw

public void draw(AbstractGraphics g)
Paints the box marker using current style foreground and background colors.

Parameters:
g - Graphics context

setBounds

public void setBounds(java.lang.Object x1,
                      java.lang.Object y1,
                      java.lang.Object x2,
                      java.lang.Object y2)
Sets rectangle bounds. Values are given in user coordinates.

Parameters:
x1 - X position value of starting corner
y1 - Y position value of starting corner
x2 - X position value of opposite corner
y2 - Y position value of opposite corner

getPaintStyle

public PaintStyle<MarkerTextPaintTags> getPaintStyle()
Description copied from class: AbstractChartObject
Gets series paint style object

Overrides:
getPaintStyle in class AbstractChartObject<MarkerTextPaintTags>
Returns:
the paintStyle object

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 AbstractChartObject<MarkerTextPaintTags>
Returns:
object paint order index