java.lang.Object | ||
↳ | org.jfree.chart.plot.Plot | |
↳ | org.jfree.chart.plot.CompassPlot |
A specialised plot that draws a compass to indicate a direction based on the
value from a ValueDataset
.
Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
int | NO_LABELS | A constant for the label type. | |||||||||
int | VALUE_LABELS | A constant for the label type. |
[Expand]
Inherited Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() |
Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
DEFAULT_LABEL_FONT | The default label font. | ||||||||||
localizationResources | The resourceBundle for the localization. | ||||||||||
revolutionDistance | The count to complete one revolution. |
[Expand]
Inherited Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() |
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Default constructor.
| |||||||||||
Constructs a new compass plot.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Adds a dataset to the compass.
| |||||||||||
Adds a dataset to the compass.
| |||||||||||
Returns a clone of the plot.
| |||||||||||
Draws the plot on a Java 2D graphics device (such as the screen or a
printer).
| |||||||||||
Tests an object for equality with this plot.
| |||||||||||
Returns an array of dataset references for the plot.
| |||||||||||
Returns a flag that controls whether or not a border is drawn.
| |||||||||||
Returns the label font.
| |||||||||||
Returns the label type.
| |||||||||||
Returns the legend items for the plot.
| |||||||||||
Returns a short string describing the type of plot.
| |||||||||||
Gets the count to complete one revolution.
| |||||||||||
Returns the paint used to fill the inner background area of the
compass.
| |||||||||||
Returns the paint used to draw the circles, symbols and labels on the
compass.
| |||||||||||
Returns the paint used to fill the outer circle of the compass.
| |||||||||||
Sets a flag that controls whether or not a border is drawn.
| |||||||||||
Sets the label font and sends a
PlotChangeEvent to all
registered listeners. | |||||||||||
Sets the label type (either
NO_LABELS or VALUE_LABELS . | |||||||||||
Sets the count to complete one revolution.
| |||||||||||
Sets the paint used to fill the inner background area of the compass,
and sends a
PlotChangeEvent to all registered listeners. | |||||||||||
Sets the paint used to draw the circles, symbols and labels of the
compass, and sends a
PlotChangeEvent to all registered listeners. | |||||||||||
Sets the paint used to fill the outer circle of the compass,
and sends a
PlotChangeEvent to all registered listeners. | |||||||||||
Sets the needle type.
| |||||||||||
Sets the needle for a series.
| |||||||||||
Sets the needle for a series and sends a
PlotChangeEvent to all
registered listeners. | |||||||||||
Sets the series outline paint.
| |||||||||||
Sets the series outline stroke.
| |||||||||||
Sets the series paint.
| |||||||||||
No zooming is implemented for compass plot, so this method is empty.
|
Protected Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Returns the font for the compass, adjusted for the size of the plot.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() | |||||||||||
![]() | |||||||||||
![]() | |||||||||||
![]() | |||||||||||
![]() | |||||||||||
![]() |
A constant for the label type.
A constant for the label type.
The count to complete one revolution. Can be arbitrarily set For degrees (the default) it is 360, for radians this is 2*Pi, etc
Default constructor.
Constructs a new compass plot.
dataset | the dataset for the plot (null permitted).
|
---|
Adds a dataset to the compass.
dataset | the new dataset (null ignored). |
---|
Adds a dataset to the compass.
dataset | the new dataset (null ignored). |
---|---|
needle | the needle (null permitted).
|
Returns a clone of the plot.
CloneNotSupportedException | this class will not throw this exception, but subclasses (if any) might. |
---|
Draws the plot on a Java 2D graphics device (such as the screen or a printer).
g2 | the graphics device. |
---|---|
area | the area within which the plot should be drawn. |
anchor | the anchor point (null permitted). |
parentState | the state from the parent plot, if there is one. |
info | collects info about the drawing. |
Tests an object for equality with this plot.
obj | the object (null permitted). |
---|
Returns an array of dataset references for the plot.
Returns a flag that controls whether or not a border is drawn.
Returns the label type. Defined by the constants: NO_LABELS
and VALUE_LABELS
.
Returns the legend items for the plot. For now, no legend is available - this method returns null.
Returns a short string describing the type of plot.
Gets the count to complete one revolution.
Returns the paint used to fill the inner background area of the compass.
null
).Returns the paint used to draw the circles, symbols and labels on the compass.
null
).Returns the paint used to fill the outer circle of the compass.
null
).Sets a flag that controls whether or not a border is drawn.
status | the flag status. |
---|
Sets the label font and sends a PlotChangeEvent
to all
registered listeners.
font | the new label font. |
---|
Sets the count to complete one revolution. Can be arbitrarily set For degrees (the default) it is 360, for radians this is 2*Pi, etc
size | the count to complete one revolution. |
---|
Sets the paint used to fill the inner background area of the compass,
and sends a PlotChangeEvent
to all registered listeners.
paint | the paint (null not permitted). |
---|
Sets the paint used to draw the circles, symbols and labels of the
compass, and sends a PlotChangeEvent
to all registered listeners.
paint | the paint (null not permitted). |
---|
Sets the paint used to fill the outer circle of the compass,
and sends a PlotChangeEvent
to all registered listeners.
paint | the paint (null not permitted). |
---|
Sets the needle for a series. The needle type is one of the following:
ArrowNeedle
;LineNeedle
;LongNeedle
;PinNeedle
;PlumNeedle
;PointerNeedle
;ShipNeedle
;WindNeedle
;ArrowNeedle
;MiddlePinNeedle
;index | the series index. |
---|---|
type | the needle type. |
Sets the needle for a series and sends a PlotChangeEvent
to all
registered listeners.
index | the series index. |
---|---|
needle | the needle. |
Sets the series outline paint.
series | the series index. |
---|---|
p | the paint. |
Sets the series outline stroke.
series | the series index. |
---|---|
stroke | the stroke. |
Sets the series paint.
series | the series index. |
---|---|
paint | the paint. |
No zooming is implemented for compass plot, so this method is empty.
percent | the zoom amount. |
---|
Returns the font for the compass, adjusted for the size of the plot.
radius | the radius. |
---|