org.jCharts.axisChart.axis
public abstract class Axis extends Object implements HTMLTestable, Serializable
Modifier and Type | Field and Description |
---|---|
private AxisChart |
axisChart |
private TextTagGroup |
axisLabelsGroup |
private float |
minimumHeightNeeded |
private float |
minimumWidthNeeded |
private int |
numberOfScaleItems |
private double |
oneUnitPixelSize |
private float |
origin |
private float |
pixelLength |
private ScaleCalculator |
scaleCalculator |
private float |
scalePixelWidth |
private float |
tickStart |
private float |
titleHeight |
private float |
titleWidth |
private float |
zeroLineCoordinate |
Constructor and Description |
---|
Axis(AxisChart axisChart,
int numberOfScaleItems)
Constructor
|
Modifier and Type | Method and Description |
---|---|
void |
computeAxisTitleDimensions(String title,
ChartFont axisTitleFont) |
void |
computeOneUnitPixelSize(float scalePixelLength,
double increment)
Computes the relationship of data point values to pixel values so know where along the axis
a value is.
|
void |
computeScalePixelWidth()
Computes the number of pixels between each value on the axis.
|
void |
computeScalePixelWidthDataAxis()
Computes the number of pixels between each value on the axis.
|
AxisChart |
getAxisChart()
Returns reference to AxisChart Object.
|
TextTagGroup |
getAxisLabelsGroup() |
float |
getMinimumHeightNeeded() |
float |
getMinimumWidthNeeded() |
int |
getNumberOfScaleItems() |
double |
getOneUnitPixelSize()
Returns the number of pixels one value unit occupies.
|
float |
getOrigin() |
float |
getPixelLength() |
ScaleCalculator |
getScaleCalculator() |
float |
getScalePixelWidth() |
float |
getTickStart() |
float |
getTitleHeight() |
float |
getTitleWidth() |
float |
getZeroLineCoordinate()
Returns the screen coordinate of the zero line.
|
void |
setAxisLabelsGroup(TextTagGroup axisLabelsGroup) |
void |
setMinimumHeightNeeded(float minimumHeightNeeded) |
void |
setMinimumWidthNeeded(float minimumWidthNeeded) |
void |
setOneUnitPixelSize(double oneUnitPixelSize) |
void |
setOrigin(float origin) |
void |
setPixelLength(float pixelLength) |
void |
setScaleCalculator(ScaleCalculator scaleCalculator) |
void |
setScalePixelWidth(float scalePixelWidth) |
void |
setTickStart(float tickStart) |
void |
setZeroLineCoordinate(float value)
Sets the screen coordinate of the zero line.
|
void |
toHTML(HTMLGenerator htmlGenerator)
Enables the testing routines to display the contents of this Object.
|
private AxisChart axisChart
private float scalePixelWidth
private float pixelLength
private float origin
private float titleHeight
private float titleWidth
private float minimumWidthNeeded
private float minimumHeightNeeded
private TextTagGroup axisLabelsGroup
private int numberOfScaleItems
private float tickStart
private double oneUnitPixelSize
private float zeroLineCoordinate
private ScaleCalculator scaleCalculator
public Axis(AxisChart axisChart, int numberOfScaleItems)
axisChart
- numberOfScaleItems
- public final AxisChart getAxisChart()
public int getNumberOfScaleItems()
public TextTagGroup getAxisLabelsGroup()
public void setAxisLabelsGroup(TextTagGroup axisLabelsGroup)
public final float getTitleWidth()
public final float getTitleHeight()
public final float getPixelLength()
public final void setPixelLength(float pixelLength)
public final float getOrigin()
public final void setOrigin(float origin)
public final float getMinimumWidthNeeded()
public final void setMinimumWidthNeeded(float minimumWidthNeeded)
public final float getMinimumHeightNeeded()
public final void setMinimumHeightNeeded(float minimumHeightNeeded)
public final float getScalePixelWidth()
public final void setScalePixelWidth(float scalePixelWidth)
public float getTickStart()
public void setTickStart(float tickStart)
public ScaleCalculator getScaleCalculator()
public void setScaleCalculator(ScaleCalculator scaleCalculator)
public final void computeAxisTitleDimensions(String title, ChartFont axisTitleFont)
title
- axisTitleFont
- public void toHTML(HTMLGenerator htmlGenerator)
toHTML
in interface HTMLTestable
htmlGenerator
- public void computeScalePixelWidth()
public void computeScalePixelWidthDataAxis()
public void setOneUnitPixelSize(double oneUnitPixelSize)
public double getOneUnitPixelSize()
public float getZeroLineCoordinate()
public void setZeroLineCoordinate(float value)
value
- the screen pixel location of the zero line.public void computeOneUnitPixelSize(float scalePixelLength, double increment)
scalePixelLength
- increment
-