|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.jrefinery.chart.AbstractRenderer | +--com.jrefinery.chart.AbstractCategoryItemRenderer | +--com.jrefinery.chart.BarRenderer | +--com.jrefinery.chart.VerticalStatisticalBarRenderer
A renderer that handles the drawing of bars for a vertical bar plot where each bar has a mean value and a standard deviation vertical line.
Fields inherited from class com.jrefinery.chart.BarRenderer |
BAR_OUTLINE_WIDTH_THRESHOLD, categoryGapSpan, categorySpan, itemGapSpan, itemSpan, itemWidth, lowerClip, upperClip, zeroInJava2D |
Constructor Summary | |
VerticalStatisticalBarRenderer()
Creates a new renderer with no tool tip or URL generator. |
|
VerticalStatisticalBarRenderer(CategoryToolTipGenerator toolTipGenerator)
Creates a new renderer with the specified tool tip generator. |
|
VerticalStatisticalBarRenderer(CategoryToolTipGenerator toolTipGenerator,
CategoryURLGenerator urlGenerator)
Creates a new renderer with the specified tool tip generator. |
|
VerticalStatisticalBarRenderer(CategoryURLGenerator urlGenerator)
Creates a new renderer with the specified URL generator. |
Method Summary | |
int |
barWidthsPerCategory(CategoryDataset data)
Returns the number of bar-widths displayed in each category. |
void |
drawCategoryItem(java.awt.Graphics2D g2,
java.awt.geom.Rectangle2D dataArea,
CategoryPlot plot,
ValueAxis axis,
CategoryDataset data,
int series,
java.lang.Object category,
int categoryIndex,
java.lang.Object previousCategory)
Draws the bar with its standard deviation line range for a single (series, category) data item. |
void |
drawRangeMarker(java.awt.Graphics2D g2,
CategoryPlot plot,
ValueAxis axis,
Marker marker,
java.awt.geom.Rectangle2D axisDataArea,
java.awt.Shape dataClipRegion)
Draws a line (or some other marker) to indicate a certain value on the range axis. |
java.awt.geom.Rectangle2D |
getAxisArea(java.awt.geom.Rectangle2D plotArea)
Returns the area that the axes (and data) must fit into. |
boolean |
hasItemGaps()
Returns true, since for this renderer there are gaps between the items in one category. |
void |
initialise(java.awt.Graphics2D g2,
java.awt.geom.Rectangle2D dataArea,
CategoryPlot plot,
ValueAxis axis,
CategoryDataset data,
ChartRenderingInfo info)
Initialises the renderer. |
Methods inherited from class com.jrefinery.chart.BarRenderer |
calculateCategoryAndItemSpans, isStacked |
Methods inherited from class com.jrefinery.chart.AbstractCategoryItemRenderer |
drawPlotBackground, getCategoriesPaint, getCategoryPaint, getDataClipRegion, getLegendItem, getPlot, getToolTipGenerator, getURLGenerator, getUseCategoriesPaint, setCategoriesPaint, setPlot, setToolTipGenerator, setURLGenerator |
Methods inherited from class com.jrefinery.chart.AbstractRenderer |
addPropertyChangeListener, firePropertyChanged, getInfo, removePropertyChangeListener, setInfo |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface com.jrefinery.chart.CategoryItemRenderer |
drawPlotBackground, getDataClipRegion, getLegendItem, getPlot, isStacked, setPlot |
Constructor Detail |
public VerticalStatisticalBarRenderer()
public VerticalStatisticalBarRenderer(CategoryToolTipGenerator toolTipGenerator)
toolTipGenerator
- the tooltip generatorpublic VerticalStatisticalBarRenderer(CategoryURLGenerator urlGenerator)
urlGenerator
- the URL generatorpublic VerticalStatisticalBarRenderer(CategoryToolTipGenerator toolTipGenerator, CategoryURLGenerator urlGenerator)
toolTipGenerator
- the tooltip generatorurlGenerator
- the URL generatorMethod Detail |
public void initialise(java.awt.Graphics2D g2, java.awt.geom.Rectangle2D dataArea, CategoryPlot plot, ValueAxis axis, CategoryDataset data, ChartRenderingInfo info)
This method gets called once at the start of the process of drawing a chart.
initialise
in interface CategoryItemRenderer
initialise
in class BarRenderer
g2
- the graphics device.dataArea
- the area in which the data is to be plotted.plot
- the plot.axis
- the axis.data
- the data.info
- collects chart rendering information for return to caller.public void drawRangeMarker(java.awt.Graphics2D g2, CategoryPlot plot, ValueAxis axis, Marker marker, java.awt.geom.Rectangle2D axisDataArea, java.awt.Shape dataClipRegion)
drawRangeMarker
in interface CategoryItemRenderer
g2
- the graphics device.plot
- the plot.axis
- the value axis.marker
- the marker.axisDataArea
- the area defined by the axes.dataClipRegion
- the data clip region.public void drawCategoryItem(java.awt.Graphics2D g2, java.awt.geom.Rectangle2D dataArea, CategoryPlot plot, ValueAxis axis, CategoryDataset data, int series, java.lang.Object category, int categoryIndex, java.lang.Object previousCategory)
drawCategoryItem
in interface CategoryItemRenderer
g2
- the graphics device.dataArea
- the data area.plot
- the plot.axis
- the range axis.data
- the data.series
- the series number (zero-based index).category
- the category.categoryIndex
- the category number (zero-based index).previousCategory
- the previous category.public boolean hasItemGaps()
hasItemGaps
in class BarRenderer
public int barWidthsPerCategory(CategoryDataset data)
barWidthsPerCategory
in class BarRenderer
data
- the dataset.public java.awt.geom.Rectangle2D getAxisArea(java.awt.geom.Rectangle2D plotArea)
Often this is the same as the plotArea, but sometimes a smaller region should be used (for example, the 3D charts require the axes to use less space in order to leave room for the 'depth' part of the chart).
getAxisArea
in interface CategoryItemRenderer
getAxisArea
in class AbstractCategoryItemRenderer
plotArea
- The plot area.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |