| java.lang.Object org.jfree.chart.axis.Axis org.jfree.chart.axis.ValueAxis org.jfree.chart.axis.NumberAxis org.jfree.chart.axis.SymbolAxis
SymbolAxis | public class SymbolAxis extends NumberAxis implements Serializable(Code) | | A standard linear value axis that replaces integer values with symbols.
|
Constructor Summary | |
public | SymbolAxis(String label, String[] sv) Constructs a symbol axis, using default attribute values where
necessary. |
Method Summary | |
protected void | autoAdjustRange() Rescales the axis to ensure that all data is visible. | public AxisState | draw(Graphics2D g2, double cursor, Rectangle2D plotArea, Rectangle2D dataArea, RectangleEdge edge, PlotRenderingInfo plotState) Draws the axis on a Java 2D graphics device (such as the screen or a
printer).
Parameters: g2 - the graphics device (null not permitted). Parameters: cursor - the cursor location. Parameters: plotArea - the area within which the plot and axes should be drawn(null not permitted). Parameters: dataArea - the area within which the data should be drawn (null not permitted). Parameters: edge - the axis location (null not permitted). Parameters: plotState - collects information about the plot (null permitted). | protected void | drawGridBands(Graphics2D g2, Rectangle2D plotArea, Rectangle2D dataArea, RectangleEdge edge, List ticks) Draws the grid bands. | protected void | drawGridBandsHorizontal(Graphics2D g2, Rectangle2D plotArea, Rectangle2D dataArea, boolean firstGridBandIsDark, List ticks) Draws the grid bands for the axis when it is at the top or bottom of
the plot. | protected void | drawGridBandsVertical(Graphics2D g2, Rectangle2D drawArea, Rectangle2D plotArea, boolean firstGridBandIsDark, List ticks) Draws the grid bands for the axis when it is at the top or bottom of
the plot. | public boolean | equals(Object obj) Tests this axis for equality with an arbitrary object.
Parameters: obj - the object (null permitted). | public Paint | getGridBandPaint() Returns the paint used to color the grid bands. | public String[] | getSymbols() Returns an array of the symbols for the axis. | public boolean | isGridBandsVisible() Returns true if the grid bands are showing, and
false otherwise. | public List | refreshTicks(Graphics2D g2, AxisState state, Rectangle2D dataArea, RectangleEdge edge) Calculates the positions of the tick labels for the axis, storing the
results in the tick label list (ready for drawing).
Parameters: g2 - the graphics device. Parameters: state - the axis state. Parameters: dataArea - the area in which the data should be drawn. Parameters: edge - the location of the axis. | protected List | refreshTicksHorizontal(Graphics2D g2, Rectangle2D dataArea, RectangleEdge edge) Calculates the positions of the tick labels for the axis, storing the
results in the tick label list (ready for drawing).
Parameters: g2 - the graphics device. Parameters: dataArea - the area in which the data should be drawn. Parameters: edge - the location of the axis. | protected List | refreshTicksVertical(Graphics2D g2, Rectangle2D dataArea, RectangleEdge edge) Calculates the positions of the tick labels for the axis, storing the
results in the tick label list (ready for drawing).
Parameters: g2 - the graphics device. Parameters: dataArea - the area in which the plot should be drawn. Parameters: edge - the location of the axis. | protected void | selectAutoTickUnit(Graphics2D g2, Rectangle2D dataArea, RectangleEdge edge) This operation is not supported by this axis. | public void | setGridBandPaint(Paint paint) Sets the grid band paint and sends an
AxisChangeEvent to
all registered listeners. | public void | setGridBandsVisible(boolean flag) Sets the visibility of the grid bands and notifies registered
listeners that the axis has been modified. | public String | valueToString(double value) Converts a value to a string, using the list of symbols.
Parameters: value - value to convert. |
DEFAULT_GRID_BAND_PAINT | final public static Paint DEFAULT_GRID_BAND_PAINT(Code) | | The default grid band paint.
|
SymbolAxis | public SymbolAxis(String label, String[] sv)(Code) | | Constructs a symbol axis, using default attribute values where
necessary.
Parameters: label - the axis label (null permitted). Parameters: sv - the list of symbols to display instead of the numericvalues. |
autoAdjustRange | protected void autoAdjustRange()(Code) | | Rescales the axis to ensure that all data is visible.
|
draw | public AxisState draw(Graphics2D g2, double cursor, Rectangle2D plotArea, Rectangle2D dataArea, RectangleEdge edge, PlotRenderingInfo plotState)(Code) | | Draws the axis on a Java 2D graphics device (such as the screen or a
printer).
Parameters: g2 - the graphics device (null not permitted). Parameters: cursor - the cursor location. Parameters: plotArea - the area within which the plot and axes should be drawn(null not permitted). Parameters: dataArea - the area within which the data should be drawn (null not permitted). Parameters: edge - the axis location (null not permitted). Parameters: plotState - collects information about the plot (null permitted). The axis state (never null ). |
drawGridBands | protected void drawGridBands(Graphics2D g2, Rectangle2D plotArea, Rectangle2D dataArea, RectangleEdge edge, List ticks)(Code) | | Draws the grid bands. Alternate bands are colored using
gridBandPaint (DEFAULT_GRID_BAND_PAINT by
default).
Parameters: g2 - the graphics device. Parameters: plotArea - the area within which the chart should be drawn. Parameters: dataArea - the area within which the plot should be drawn (a subset of the drawArea). Parameters: edge - the axis location. Parameters: ticks - the ticks. |
drawGridBandsHorizontal | protected void drawGridBandsHorizontal(Graphics2D g2, Rectangle2D plotArea, Rectangle2D dataArea, boolean firstGridBandIsDark, List ticks)(Code) | | Draws the grid bands for the axis when it is at the top or bottom of
the plot.
Parameters: g2 - the graphics device. Parameters: plotArea - the area within which the chart should be drawn. Parameters: dataArea - the area within which the plot should be drawn(a subset of the drawArea). Parameters: firstGridBandIsDark - True: the first grid band takes thecolor of gridBandPaint.False: the second grid band takes the color of gridBandPaint. Parameters: ticks - the ticks. |
drawGridBandsVertical | protected void drawGridBandsVertical(Graphics2D g2, Rectangle2D drawArea, Rectangle2D plotArea, boolean firstGridBandIsDark, List ticks)(Code) | | Draws the grid bands for the axis when it is at the top or bottom of
the plot.
Parameters: g2 - the graphics device. Parameters: drawArea - the area within which the chart should be drawn. Parameters: plotArea - the area within which the plot should be drawn (asubset of the drawArea). Parameters: firstGridBandIsDark - True: the first grid band takes thecolor of gridBandPaint.False: the second grid band takes the color of gridBandPaint. Parameters: ticks - a list of ticks. |
equals | public boolean equals(Object obj)(Code) | | Tests this axis for equality with an arbitrary object.
Parameters: obj - the object (null permitted). A boolean. |
getSymbols | public String[] getSymbols()(Code) | | Returns an array of the symbols for the axis.
The symbols. |
isGridBandsVisible | public boolean isGridBandsVisible()(Code) | | Returns true if the grid bands are showing, and
false otherwise.
true if the grid bands are showing, and false otherwise. See Also: SymbolAxis.setGridBandsVisible(boolean) |
refreshTicks | public List refreshTicks(Graphics2D g2, AxisState state, Rectangle2D dataArea, RectangleEdge edge)(Code) | | Calculates the positions of the tick labels for the axis, storing the
results in the tick label list (ready for drawing).
Parameters: g2 - the graphics device. Parameters: state - the axis state. Parameters: dataArea - the area in which the data should be drawn. Parameters: edge - the location of the axis. A list of ticks. |
refreshTicksHorizontal | protected List refreshTicksHorizontal(Graphics2D g2, Rectangle2D dataArea, RectangleEdge edge)(Code) | | Calculates the positions of the tick labels for the axis, storing the
results in the tick label list (ready for drawing).
Parameters: g2 - the graphics device. Parameters: dataArea - the area in which the data should be drawn. Parameters: edge - the location of the axis. The ticks. |
refreshTicksVertical | protected List refreshTicksVertical(Graphics2D g2, Rectangle2D dataArea, RectangleEdge edge)(Code) | | Calculates the positions of the tick labels for the axis, storing the
results in the tick label list (ready for drawing).
Parameters: g2 - the graphics device. Parameters: dataArea - the area in which the plot should be drawn. Parameters: edge - the location of the axis. The ticks. |
selectAutoTickUnit | protected void selectAutoTickUnit(Graphics2D g2, Rectangle2D dataArea, RectangleEdge edge)(Code) | | This operation is not supported by this axis.
Parameters: g2 - the graphics device. Parameters: dataArea - the area in which the plot and axes should be drawn. Parameters: edge - the edge along which the axis is drawn. |
setGridBandsVisible | public void setGridBandsVisible(boolean flag)(Code) | | Sets the visibility of the grid bands and notifies registered
listeners that the axis has been modified.
Parameters: flag - the new setting. See Also: SymbolAxis.isGridBandsVisible() |
valueToString | public String valueToString(double value)(Code) | | Converts a value to a string, using the list of symbols.
Parameters: value - value to convert. The symbol. |
Methods inherited from org.jfree.chart.axis.NumberAxis | protected void autoAdjustRange()(Code)(Java Doc) protected double calculateHighestVisibleTickValue()(Code)(Java Doc) protected double calculateLowestVisibleTickValue()(Code)(Java Doc) protected int calculateVisibleTickCount()(Code)(Java Doc) public Object clone() throws CloneNotSupportedException(Code)(Java Doc) public void configure()(Code)(Java Doc) public static TickUnitSource createIntegerTickUnits()(Code)(Java Doc) public static TickUnitSource createIntegerTickUnits(Locale locale)(Code)(Java Doc) public static TickUnitSource createStandardTickUnits()(Code)(Java Doc) public static TickUnitSource createStandardTickUnits(Locale locale)(Code)(Java Doc) public AxisState draw(Graphics2D g2, double cursor, Rectangle2D plotArea, Rectangle2D dataArea, RectangleEdge edge, PlotRenderingInfo plotState)(Code)(Java Doc) public boolean equals(Object obj)(Code)(Java Doc) protected double estimateMaximumTickLabelHeight(Graphics2D g2)(Code)(Java Doc) protected double estimateMaximumTickLabelWidth(Graphics2D g2, TickUnit unit)(Code)(Java Doc) public boolean getAutoRangeIncludesZero()(Code)(Java Doc) public boolean getAutoRangeStickyZero()(Code)(Java Doc) public MarkerAxisBand getMarkerBand()(Code)(Java Doc) public NumberFormat getNumberFormatOverride()(Code)(Java Doc) public RangeType getRangeType()(Code)(Java Doc) public NumberTickUnit getTickUnit()(Code)(Java Doc) public int hashCode()(Code)(Java Doc) public double java2DToValue(double java2DValue, Rectangle2D area, RectangleEdge edge)(Code)(Java Doc) public List refreshTicks(Graphics2D g2, AxisState state, Rectangle2D dataArea, RectangleEdge edge)(Code)(Java Doc) protected List refreshTicksHorizontal(Graphics2D g2, Rectangle2D dataArea, RectangleEdge edge)(Code)(Java Doc) protected List refreshTicksVertical(Graphics2D g2, Rectangle2D dataArea, RectangleEdge edge)(Code)(Java Doc) protected void selectAutoTickUnit(Graphics2D g2, Rectangle2D dataArea, RectangleEdge edge)(Code)(Java Doc) protected void selectHorizontalAutoTickUnit(Graphics2D g2, Rectangle2D dataArea, RectangleEdge edge)(Code)(Java Doc) protected void selectVerticalAutoTickUnit(Graphics2D g2, Rectangle2D dataArea, RectangleEdge edge)(Code)(Java Doc) public void setAutoRangeIncludesZero(boolean flag)(Code)(Java Doc) public void setAutoRangeStickyZero(boolean flag)(Code)(Java Doc) public void setMarkerBand(MarkerAxisBand band)(Code)(Java Doc) public void setNumberFormatOverride(NumberFormat formatter)(Code)(Java Doc) public void setRangeType(RangeType rangeType)(Code)(Java Doc) public void setTickUnit(NumberTickUnit unit)(Code)(Java Doc) public void setTickUnit(NumberTickUnit unit, boolean notify, boolean turnOffAutoSelect)(Code)(Java Doc) public double valueToJava2D(double value, Rectangle2D area, RectangleEdge edge)(Code)(Java Doc)
|
Methods inherited from org.jfree.chart.axis.ValueAxis | abstract protected void autoAdjustRange()(Code)(Java Doc) protected float[] calculateAnchorPoint(ValueTick tick, double cursor, Rectangle2D dataArea, RectangleEdge edge)(Code)(Java Doc) public void centerRange(double value)(Code)(Java Doc) public Object clone() throws CloneNotSupportedException(Code)(Java Doc) protected void drawAxisLine(Graphics2D g2, double cursor, Rectangle2D dataArea, RectangleEdge edge)(Code)(Java Doc) protected AxisState drawTickMarksAndLabels(Graphics2D g2, double cursor, Rectangle2D plotArea, Rectangle2D dataArea, RectangleEdge edge)(Code)(Java Doc) public boolean equals(Object obj)(Code)(Java Doc) protected double findMaximumTickLabelHeight(List ticks, Graphics2D g2, Rectangle2D drawArea, boolean vertical)(Code)(Java Doc) protected double findMaximumTickLabelWidth(List ticks, Graphics2D g2, Rectangle2D drawArea, boolean vertical)(Code)(Java Doc) public double getAutoRangeMinimumSize()(Code)(Java Doc) protected int getAutoTickIndex()(Code)(Java Doc) public Range getDefaultAutoRange()(Code)(Java Doc) public Shape getDownArrow()(Code)(Java Doc) public double getFixedAutoRange()(Code)(Java Doc) public Shape getLeftArrow()(Code)(Java Doc) public double getLowerBound()(Code)(Java Doc) public double getLowerMargin()(Code)(Java Doc) public Range getRange()(Code)(Java Doc) public Shape getRightArrow()(Code)(Java Doc) public TickUnitSource getStandardTickUnits()(Code)(Java Doc) public Shape getUpArrow()(Code)(Java Doc) public double getUpperBound()(Code)(Java Doc) public double getUpperMargin()(Code)(Java Doc) public boolean isAutoRange()(Code)(Java Doc) public boolean isAutoTickUnitSelection()(Code)(Java Doc) public boolean isInverted()(Code)(Java Doc) public boolean isNegativeArrowVisible()(Code)(Java Doc) public boolean isPositiveArrowVisible()(Code)(Java Doc) public boolean isVerticalTickLabels()(Code)(Java Doc) abstract public double java2DToValue(double java2DValue, Rectangle2D area, RectangleEdge edge)(Code)(Java Doc) public double lengthToJava2D(double length, Rectangle2D area, RectangleEdge edge)(Code)(Java Doc) public AxisSpace reserveSpace(Graphics2D g2, Plot plot, Rectangle2D plotArea, RectangleEdge edge, AxisSpace space)(Code)(Java Doc) public void resizeRange(double percent)(Code)(Java Doc) public void resizeRange(double percent, double anchorValue)(Code)(Java Doc) public void setAutoRange(boolean auto)(Code)(Java Doc) protected void setAutoRange(boolean auto, boolean notify)(Code)(Java Doc) public void setAutoRangeMinimumSize(double size)(Code)(Java Doc) public void setAutoRangeMinimumSize(double size, boolean notify)(Code)(Java Doc) protected void setAutoTickIndex(int index)(Code)(Java Doc) public void setAutoTickUnitSelection(boolean flag)(Code)(Java Doc) public void setAutoTickUnitSelection(boolean flag, boolean notify)(Code)(Java Doc) public void setDefaultAutoRange(Range range)(Code)(Java Doc) public void setDownArrow(Shape arrow)(Code)(Java Doc) public void setFixedAutoRange(double length)(Code)(Java Doc) public void setInverted(boolean flag)(Code)(Java Doc) public void setLeftArrow(Shape arrow)(Code)(Java Doc) public void setLowerBound(double min)(Code)(Java Doc) public void setLowerMargin(double margin)(Code)(Java Doc) public void setNegativeArrowVisible(boolean visible)(Code)(Java Doc) public void setPositiveArrowVisible(boolean visible)(Code)(Java Doc) public void setRange(Range range)(Code)(Java Doc) public void setRange(Range range, boolean turnOffAutoRange, boolean notify)(Code)(Java Doc) public void setRange(double lower, double upper)(Code)(Java Doc) public void setRangeAboutValue(double value, double length)(Code)(Java Doc) public void setRangeWithMargins(Range range)(Code)(Java Doc) public void setRangeWithMargins(Range range, boolean turnOffAutoRange, boolean notify)(Code)(Java Doc) public void setRangeWithMargins(double lower, double upper)(Code)(Java Doc) public void setRightArrow(Shape arrow)(Code)(Java Doc) public void setStandardTickUnits(TickUnitSource source)(Code)(Java Doc) public void setUpArrow(Shape arrow)(Code)(Java Doc) public void setUpperBound(double max)(Code)(Java Doc) public void setUpperMargin(double margin)(Code)(Java Doc) public void setVerticalTickLabels(boolean flag)(Code)(Java Doc) abstract public double valueToJava2D(double value, Rectangle2D area, RectangleEdge edge)(Code)(Java Doc) public void zoomRange(double lowerPercent, double upperPercent)(Code)(Java Doc)
|
Methods inherited from org.jfree.chart.axis.Axis | public void addChangeListener(AxisChangeListener listener)(Code)(Java Doc) public Object clone() throws CloneNotSupportedException(Code)(Java Doc) abstract public void configure()(Code)(Java Doc) abstract public AxisState draw(Graphics2D g2, double cursor, Rectangle2D plotArea, Rectangle2D dataArea, RectangleEdge edge, PlotRenderingInfo plotState)(Code)(Java Doc) protected void drawAxisLine(Graphics2D g2, double cursor, Rectangle2D dataArea, RectangleEdge edge)(Code)(Java Doc) protected AxisState drawLabel(String label, Graphics2D g2, Rectangle2D plotArea, Rectangle2D dataArea, RectangleEdge edge, AxisState state)(Code)(Java Doc) public boolean equals(Object obj)(Code)(Java Doc) public Paint getAxisLinePaint()(Code)(Java Doc) public Stroke getAxisLineStroke()(Code)(Java Doc) public double getFixedDimension()(Code)(Java Doc) public String getLabel()(Code)(Java Doc) public double getLabelAngle()(Code)(Java Doc) protected Rectangle2D getLabelEnclosure(Graphics2D g2, RectangleEdge edge)(Code)(Java Doc) public Font getLabelFont()(Code)(Java Doc) public RectangleInsets getLabelInsets()(Code)(Java Doc) public Paint getLabelPaint()(Code)(Java Doc) public Plot getPlot()(Code)(Java Doc) public Font getTickLabelFont()(Code)(Java Doc) public RectangleInsets getTickLabelInsets()(Code)(Java Doc) public Paint getTickLabelPaint()(Code)(Java Doc) public float getTickMarkInsideLength()(Code)(Java Doc) public float getTickMarkOutsideLength()(Code)(Java Doc) public Paint getTickMarkPaint()(Code)(Java Doc) public Stroke getTickMarkStroke()(Code)(Java Doc) public boolean hasListener(EventListener listener)(Code)(Java Doc) public boolean isAxisLineVisible()(Code)(Java Doc) public boolean isTickLabelsVisible()(Code)(Java Doc) public boolean isTickMarksVisible()(Code)(Java Doc) public boolean isVisible()(Code)(Java Doc) protected void notifyListeners(AxisChangeEvent event)(Code)(Java Doc) abstract public List refreshTicks(Graphics2D g2, AxisState state, Rectangle2D dataArea, RectangleEdge edge)(Code)(Java Doc) public void removeChangeListener(AxisChangeListener listener)(Code)(Java Doc) abstract public AxisSpace reserveSpace(Graphics2D g2, Plot plot, Rectangle2D plotArea, RectangleEdge edge, AxisSpace space)(Code)(Java Doc) public void setAxisLinePaint(Paint paint)(Code)(Java Doc) public void setAxisLineStroke(Stroke stroke)(Code)(Java Doc) public void setAxisLineVisible(boolean visible)(Code)(Java Doc) public void setFixedDimension(double dimension)(Code)(Java Doc) public void setLabel(String label)(Code)(Java Doc) public void setLabelAngle(double angle)(Code)(Java Doc) public void setLabelFont(Font font)(Code)(Java Doc) public void setLabelInsets(RectangleInsets insets)(Code)(Java Doc) public void setLabelPaint(Paint paint)(Code)(Java Doc) public void setPlot(Plot plot)(Code)(Java Doc) public void setTickLabelFont(Font font)(Code)(Java Doc) public void setTickLabelInsets(RectangleInsets insets)(Code)(Java Doc) public void setTickLabelPaint(Paint paint)(Code)(Java Doc) public void setTickLabelsVisible(boolean flag)(Code)(Java Doc) public void setTickMarkInsideLength(float length)(Code)(Java Doc) public void setTickMarkOutsideLength(float length)(Code)(Java Doc) public void setTickMarkPaint(Paint paint)(Code)(Java Doc) public void setTickMarkStroke(Stroke stroke)(Code)(Java Doc) public void setTickMarksVisible(boolean flag)(Code)(Java Doc) public void setVisible(boolean flag)(Code)(Java Doc)
|
|
|