Package org.jfree.chart.renderer
Class DefaultPolarItemRenderer
java.lang.Object
org.jfree.chart.renderer.AbstractRenderer
org.jfree.chart.renderer.DefaultPolarItemRenderer
- All Implemented Interfaces:
Serializable
,Cloneable
,PolarItemRenderer
public class DefaultPolarItemRenderer extends AbstractRenderer implements PolarItemRenderer
A renderer that can be used with the
PolarPlot
class.- Author:
- Daniel Bridenbecker, Solution Engineering, Inc.
- See Also:
- Serialized Form
-
Field Summary
Fields inherited from class org.jfree.chart.renderer.AbstractRenderer
DEFAULT_OUTLINE_PAINT, DEFAULT_OUTLINE_STROKE, DEFAULT_PAINT, DEFAULT_SHAPE, DEFAULT_STROKE, DEFAULT_VALUE_LABEL_FONT, DEFAULT_VALUE_LABEL_PAINT, ZERO
-
Constructor Summary
Constructors Constructor Description DefaultPolarItemRenderer()
Creates a new instance of DefaultPolarItemRenderer -
Method Summary
Modifier and Type Method Description void
drawAngularGridLines(Graphics2D g2, PolarPlot plot, List ticks, Rectangle2D dataArea)
Draw the angular gridlines - the spokes.void
drawRadialGridLines(Graphics2D g2, PolarPlot plot, ValueAxis radialAxis, List ticks, Rectangle2D dataArea)
Draw the radial gridlines - the rings.void
drawSeries(Graphics2D g2, Rectangle2D dataArea, PlotRenderingInfo info, PolarPlot plot, XYDataset dataset, int seriesIndex)
Plots the data for a given series.DrawingSupplier
getDrawingSupplier()
Returns the drawing supplier from the plot.LegendItem
getLegendItem(int series)
Return the legend for the given series.PolarPlot
getPlot()
Return the plot associated with this renderer.boolean
isSeriesFilled(int series)
Returnstrue
if the renderer should fill the specified series, andfalse
otherwise.void
setPlot(PolarPlot plot)
Set the plot associated with this renderer.void
setSeriesFilled(int series, boolean filled)
Sets a flag that controls whether or not a series is filled.Methods inherited from class org.jfree.chart.renderer.AbstractRenderer
addChangeListener, equals, getBaseItemLabelAnchor, getBaseItemLabelAngle, getBaseItemLabelFont, getBaseItemLabelPaint, getBaseItemLabelRotationAnchor, getBaseItemLabelsVisible, getBaseItemLabelTextAnchor, getBaseNegativeItemLabelPosition, getBaseOutlinePaint, getBaseOutlineStroke, getBasePaint, getBasePositiveItemLabelPosition, getBaseShape, getBaseStroke, getItemLabelAnchor, getItemLabelAnchorOffset, getItemLabelAngle, getItemLabelFont, getItemLabelFont, getItemLabelPaint, getItemLabelPaint, getItemLabelRotationAnchor, getItemLabelTextAnchor, getItemOutlinePaint, getItemOutlineStroke, getItemPaint, getItemShape, getItemStroke, getNegativeItemLabelPosition, getNegativeItemLabelPosition, getPositiveItemLabelPosition, getPositiveItemLabelPosition, getSeriesItemLabelAnchor, getSeriesItemLabelAngle, getSeriesItemLabelFont, getSeriesItemLabelPaint, getSeriesItemLabelRotationAnchor, getSeriesItemLabelTextAnchor, getSeriesNegativeItemLabelPosition, getSeriesOutlinePaint, getSeriesOutlineStroke, getSeriesPaint, getSeriesPositiveItemLabelPosition, getSeriesShape, getSeriesStroke, hashCode, isItemLabelVisible, isSeriesItemLabelsVisible, notifyListeners, removeChangeListener, setBaseAngle, setBaseItemLabelAnchor, setBaseItemLabelFont, setBaseItemLabelFont, setBaseItemLabelPaint, setBaseItemLabelPaint, setBaseItemLabelRotationAnchor, setBaseItemLabelsVisible, setBaseItemLabelsVisible, setBaseItemLabelsVisible, setBaseItemLabelTextAnchor, setBaseNegativeItemLabelPosition, setBaseNegativeItemLabelPosition, setBaseOutlinePaint, setBaseOutlinePaint, setBaseOutlineStroke, setBaseOutlineStroke, setBasePaint, setBasePaint, setBasePositiveItemLabelPosition, setBasePositiveItemLabelPosition, setBaseShape, setBaseShape, setBaseStroke, setBaseStroke, setItemLabelAnchor, setItemLabelAnchorOffset, setItemLabelAngle, setItemLabelFont, setItemLabelFont, setItemLabelPaint, setItemLabelPaint, setItemLabelRotationAnchor, setItemLabelsVisible, setItemLabelsVisible, setItemLabelsVisible, setItemLabelTextAnchor, setNegativeItemLabelPosition, setNegativeItemLabelPosition, setOutlinePaint, setOutlinePaint, setOutlineStroke, setOutlineStroke, setPaint, setPaint, setPositiveItemLabelPosition, setPositiveItemLabelPosition, setSeriesAngle, setSeriesItemLabelAnchor, setSeriesItemLabelFont, setSeriesItemLabelFont, setSeriesItemLabelPaint, setSeriesItemLabelPaint, setSeriesItemLabelRotationAnchor, setSeriesItemLabelsVisible, setSeriesItemLabelsVisible, setSeriesItemLabelsVisible, setSeriesItemLabelTextAnchor, setSeriesNegativeItemLabelPosition, setSeriesNegativeItemLabelPosition, setSeriesOutlinePaint, setSeriesOutlinePaint, setSeriesOutlineStroke, setSeriesOutlineStroke, setSeriesPaint, setSeriesPaint, setSeriesPositiveItemLabelPosition, setSeriesPositiveItemLabelPosition, setSeriesShape, setSeriesShape, setSeriesStroke, setSeriesStroke, setShape, setShape, setStroke, setStroke
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.jfree.chart.renderer.PolarItemRenderer
addChangeListener, removeChangeListener
-
Constructor Details
-
DefaultPolarItemRenderer
public DefaultPolarItemRenderer()Creates a new instance of DefaultPolarItemRenderer
-
-
Method Details
-
getDrawingSupplier
Returns the drawing supplier from the plot.- Specified by:
getDrawingSupplier
in classAbstractRenderer
- Returns:
- The drawing supplier.
-
setPlot
Set the plot associated with this renderer.- Specified by:
setPlot
in interfacePolarItemRenderer
- Parameters:
plot
- the plot.
-
getPlot
Return the plot associated with this renderer.- Specified by:
getPlot
in interfacePolarItemRenderer
- Returns:
- The plot.
-
drawSeries
public void drawSeries(Graphics2D g2, Rectangle2D dataArea, PlotRenderingInfo info, PolarPlot plot, XYDataset dataset, int seriesIndex)Plots the data for a given series.- Specified by:
drawSeries
in interfacePolarItemRenderer
- Parameters:
g2
- the drawing surface.dataArea
- the data area.info
- collects plot rendering info.plot
- the plot.dataset
- the dataset.seriesIndex
- the series index.
-
isSeriesFilled
public boolean isSeriesFilled(int series)Returnstrue
if the renderer should fill the specified series, andfalse
otherwise.- Parameters:
series
- the series index (zero-based).- Returns:
- A boolean.
-
setSeriesFilled
public void setSeriesFilled(int series, boolean filled)Sets a flag that controls whether or not a series is filled.- Parameters:
series
- the series index.filled
- the flag.
-
drawAngularGridLines
Draw the angular gridlines - the spokes.- Specified by:
drawAngularGridLines
in interfacePolarItemRenderer
- Parameters:
g2
- the drawing surface.plot
- the plot.ticks
- the ticks.dataArea
- the data area.
-
drawRadialGridLines
public void drawRadialGridLines(Graphics2D g2, PolarPlot plot, ValueAxis radialAxis, List ticks, Rectangle2D dataArea)Draw the radial gridlines - the rings.- Specified by:
drawRadialGridLines
in interfacePolarItemRenderer
- Parameters:
g2
- the drawing surface.plot
- the plot.radialAxis
- the radial axis.ticks
- the ticks.dataArea
- the data area.
-
getLegendItem
Return the legend for the given series.- Specified by:
getLegendItem
in interfacePolarItemRenderer
- Parameters:
series
- the series index.- Returns:
- The legend item.
-