Package org.jCharts.chartText
Class BarValueGroup
- java.lang.Object
-
- org.jCharts.chartText.BarValueGroup
-
public class BarValueGroup extends java.lang.Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected classBarValueGroup.BarValueHelper class to handle a barValue - wraps TextTag Meant to be called only by BarValueGroup class.
-
Field Summary
Fields Modifier and Type Field Description private AxisChartaxisChartprivate AxisPropertiesaxisPropertiesprivate BarChartPropertiesbarChartPropertiesprivate java.awt.FontbarValueFontprivate java.awt.PaintbarValueFontColorprivate intbarValueItemprivate intbarValuePositionprivate floatcenterChartprivate java.awt.font.FontRenderContextfontRenderContextprivate floathorizontalPaddingprivate booleanisVerticalprivate java.text.NumberFormatnumberFormatprivate booleanshowBarValuesprivate java.util.ArrayListtextTagListprivate doubletotalDataValueprivate floatverticalPadding
-
Constructor Summary
Constructors Constructor Description BarValueGroup(AxisChart axisChart, IAxisChartDataSet iAxisChartDataSet)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddBarValue(int i, double dataValue, java.awt.geom.Rectangle2D.Float barRect)Adds a bar value for the given data item, if barValues are onprivate java.lang.StringgetBarValueAt(int i, double dataValue)Gets the text associated (by the user) for the given bar value.private java.awt.geom.Rectangle2D.FloatgetBarValueRectangleCoordinates(int position, BarValueGroup.BarValue barValue)Gets the rectangle coords associated (by the user) for the given bar value.private floatgetBottom(java.awt.geom.Rectangle2D.Float r)Not sure why this was left out of Rectangle2D...private floatgetRight(java.awt.geom.Rectangle2D.Float r)Not sure why this was left out of Rectangle2D...voidrender(java.awt.Graphics2D g2d)renders any barValuesprivate voidsetBarValuePosition(BarValueGroup.BarValue barValue, java.awt.geom.Rectangle2D.Float bounds)Gets the rectangle associated (by the user) for the given bar value.
-
-
-
Field Detail
-
axisChart
private AxisChart axisChart
-
fontRenderContext
private java.awt.font.FontRenderContext fontRenderContext
-
isVertical
private boolean isVertical
-
barChartProperties
private BarChartProperties barChartProperties
-
axisProperties
private AxisProperties axisProperties
-
numberFormat
private java.text.NumberFormat numberFormat
-
showBarValues
private boolean showBarValues
-
barValuePosition
private int barValuePosition
-
barValueItem
private int barValueItem
-
barValueFont
private java.awt.Font barValueFont
-
barValueFontColor
private java.awt.Paint barValueFontColor
-
horizontalPadding
private float horizontalPadding
-
verticalPadding
private float verticalPadding
-
totalDataValue
private double totalDataValue
-
centerChart
private float centerChart
-
textTagList
private java.util.ArrayList textTagList
-
-
Constructor Detail
-
BarValueGroup
public BarValueGroup(AxisChart axisChart, IAxisChartDataSet iAxisChartDataSet)
-
-
Method Detail
-
getBarValueAt
private java.lang.String getBarValueAt(int i, double dataValue)Gets the text associated (by the user) for the given bar value. Meant only to be called by BarChart.render()
-
getBarValueRectangleCoordinates
private java.awt.geom.Rectangle2D.Float getBarValueRectangleCoordinates(int position, BarValueGroup.BarValue barValue)Gets the rectangle coords associated (by the user) for the given bar value. Meant only to be called by BarChart.render()
-
getRight
private float getRight(java.awt.geom.Rectangle2D.Float r)
Not sure why this was left out of Rectangle2D...
-
getBottom
private float getBottom(java.awt.geom.Rectangle2D.Float r)
Not sure why this was left out of Rectangle2D...
-
setBarValuePosition
private void setBarValuePosition(BarValueGroup.BarValue barValue, java.awt.geom.Rectangle2D.Float bounds)
Gets the rectangle associated (by the user) for the given bar value. Meant only to be called by BarChart.render()
-
addBarValue
public void addBarValue(int i, double dataValue, java.awt.geom.Rectangle2D.Float barRect)Adds a bar value for the given data item, if barValues are on
-
render
public void render(java.awt.Graphics2D g2d)
renders any barValues
-
-