public class BarRenderer<FormatterType extends BarFormatter> extends GroupRenderer<FormatterType>
BarRenderer.BarOrientation
javadoc for details on supported
presentation styles.Modifier and Type | Class and Description |
---|---|
static class |
BarRenderer.Bar<FormatterType extends BarFormatter> |
static class |
BarRenderer.BarComparator
Used to determine the order in which bars of the same group will be drawn.
|
static class |
BarRenderer.BarGroupWidthMode
Mode with which to calculate the width of each bar.
|
static class |
BarRenderer.BarOrientation
How bars should be laid out when in a group of 2 or more series.
|
Constructor and Description |
---|
BarRenderer(XYPlot plot) |
Modifier and Type | Method and Description |
---|---|
protected android.graphics.RectF |
createBarRect(float w1,
float h1,
float w2,
float h2,
BarFormatter formatter) |
void |
doDrawLegendIcon(android.graphics.Canvas canvas,
android.graphics.RectF rect,
BarFormatter formatter)
Draw the legend icon in the rect passed in.
|
protected void |
drawBar(android.graphics.Canvas canvas,
BarRenderer.Bar bar,
android.graphics.RectF rect) |
protected BarRenderer.BarComparator |
getBarComparator(float rangeOriginPx) |
float |
getBarGroupWidth() |
BarRenderer.BarGroupWidthMode |
getBarGroupWidthMode() |
BarRenderer.BarOrientation |
getBarOrientation() |
FormatterType |
getFormatter(int index,
XYSeries series)
Retrieves the BarFormatter instance that corresponds with the series passed in.
|
void |
onRender(android.graphics.Canvas canvas,
android.graphics.RectF plotArea,
List<SeriesBundle<XYSeries,? extends FormatterType>> sfList,
int seriesSize,
RenderStack stack) |
void |
setBarGroupWidth(BarRenderer.BarGroupWidthMode mode,
float width) |
void |
setBarOrientation(BarRenderer.BarOrientation renderBarOrientation) |
onRender
getUniqueRegionFormatters
drawSeriesLegendIcon, getFormatter, getPlot, getSeriesAndFormatterList, getSeriesList, render, setPlot
public BarRenderer(XYPlot plot)
public void setBarOrientation(BarRenderer.BarOrientation renderBarOrientation)
public BarRenderer.BarOrientation getBarOrientation()
public BarRenderer.BarGroupWidthMode getBarGroupWidthMode()
public float getBarGroupWidth()
public void setBarGroupWidth(BarRenderer.BarGroupWidthMode mode, float width)
protected BarRenderer.BarComparator getBarComparator(float rangeOriginPx)
public void doDrawLegendIcon(android.graphics.Canvas canvas, android.graphics.RectF rect, BarFormatter formatter)
SeriesRenderer
doDrawLegendIcon
in class SeriesRenderer<XYPlot,XYSeries,FormatterType extends BarFormatter>
public FormatterType getFormatter(int index, XYSeries series)
index
- index of the point being rendered.series
- XYSeries to which the point being rendered belongs.public void onRender(android.graphics.Canvas canvas, android.graphics.RectF plotArea, List<SeriesBundle<XYSeries,? extends FormatterType>> sfList, int seriesSize, RenderStack stack)
onRender
in class GroupRenderer<FormatterType extends BarFormatter>
protected android.graphics.RectF createBarRect(float w1, float h1, float w2, float h2, BarFormatter formatter)
protected void drawBar(android.graphics.Canvas canvas, BarRenderer.Bar bar, android.graphics.RectF rect)