An axis which is composed of title and tick. More...
Public Types | |
enum | Direction { X, Y } |
An axis direction. More... | |
enum | Position { Primary, Secondary } |
An axis position. More... | |
Public Member Functions | |
int | getId () |
Gets the axis id. | |
Direction | getDirection () |
Gets the axis direction. | |
Position | getPosition () |
Gets the axis position. | |
void | setPosition (Position position) |
Sets the axis position. | |
void | setRange (Range range) |
Sets the axis range. | |
Range | getRange () |
Gets the axis range. | |
ITitle | getTitle () |
Gets the axis title. | |
IAxisTick | getTick () |
Gets the axis tick. | |
void | enableLogScale (boolean enabled) throws IllegalStateException |
Enables the log scale. | |
boolean | isLogScaleEnabled () |
Gets the state indicating if log scale is enabled. | |
IGrid | getGrid () |
Gets the grid. | |
void | adjustRange () |
Adjusts the axis range to the series belonging to the axis, so that all series are completely shown. | |
void | zoomIn () |
Zooms in the axis. | |
void | zoomIn (double coordinate) |
Zooms in the axis at the given coordinate. | |
void | zoomOut () |
Zooms out the axis. | |
void | zoomOut (double coordinate) |
Zooms out the axis at the given coordinate. | |
void | scrollUp () |
Scrolls up the axis. | |
void | scrollDown () |
Scrolls up the axis. | |
void | enableCategory (boolean enabled) |
Enables category. | |
boolean | isCategoryEnabled () |
Gets the state indicating if category is enabled. | |
void | setCategorySeries (String[] series) |
Sets the category series. | |
String[] | getCategorySeries () |
Gets the category series. | |
int | getPixelCoordinate (double dataCoordinate) |
Gets the pixel coordinate corresponding to the given data coordinate. | |
double | getDataCoordinate (int pixelCoordinate) |
Gets the data coordinate corresponding to the given pixel coordinate on plot area. | |
void | addDisposeListener (IDisposeListener listener) |
Adds the dispose listener. |
An axis which is composed of title and tick.
Grid is associated with axis.
Definition at line 12 of file IAxis.java.
An axis direction.
Definition at line 15 of file IAxis.java.
An axis position.
Definition at line 25 of file IAxis.java.
void org.swtchart.IAxis.addDisposeListener | ( | IDisposeListener | listener | ) |
Adds the dispose listener.
The newly created color or font for axis can be disposed with the dispose listener when they are no longer needed.
listener | the dispose listener |
Implemented in org.swtchart.internal.axis.Axis.
Referenced by org.swtchart.ext.internal.properties.AxisTickPage.apply(), and org.swtchart.ext.internal.properties.AxisPage.apply().
void org.swtchart.IAxis.adjustRange | ( | ) |
Adjusts the axis range to the series belonging to the axis, so that all series are completely shown.
Implemented in org.swtchart.internal.axis.Axis.
void org.swtchart.IAxis.enableCategory | ( | boolean | enabled | ) |
Enables category.
Category is applicable only for X axis. If enabling category, log scale will be disabled. If category series are not yet set, category won't be enabled.
enabled | true if enabling category |
Implemented in org.swtchart.internal.axis.Axis.
Referenced by org.swtchart.ext.internal.properties.AxisPage.apply(), org.swtchart.examples.StackSeriesExample.createChart(), org.swtchart.examples.CategoryExample.createChart(), org.swtchart.examples.AngledAxisTickLabelsExample.createChart(), and org.swtchart.examples.ext.InteractiveChartExample.createPartControl().
void org.swtchart.IAxis.enableLogScale | ( | boolean | enabled | ) | throws IllegalStateException |
Enables the log scale.
If enabling log scale, stacking trace and category axis will be disabled.
enabled | true if enabling log scales |
IllegalStateException | if minimum value of series belonging to this axis is less than zero. |
Implemented in org.swtchart.internal.axis.Axis.
Referenced by org.swtchart.ext.internal.properties.AxisPage.apply(), org.swtchart.examples.LogScaleExample.createChart(), org.swtchart.internal.series.Series.setXAxisId(), org.swtchart.internal.series.Series.setXSeries(), and org.swtchart.internal.series.Series.setYSeries().
String [] org.swtchart.IAxis.getCategorySeries | ( | ) |
Gets the category series.
If the category series haven't been set yet, null
will be returned.
Implemented in org.swtchart.internal.axis.Axis.
double org.swtchart.IAxis.getDataCoordinate | ( | int | pixelCoordinate | ) |
Gets the data coordinate corresponding to the given pixel coordinate on plot area.
pixelCoordinate | the pixel coordinate on plot area |
Implemented in org.swtchart.internal.axis.Axis.
Referenced by org.swtchart.examples.advanced.PxielToDataConversionExample.createChart(), and org.swtchart.ext.InteractiveChart.setRange().
Direction org.swtchart.IAxis.getDirection | ( | ) |
Gets the axis direction.
The axis direction is set when axis is created, and won't be changed.
Implemented in org.swtchart.internal.axis.Axis.
Referenced by org.swtchart.ext.internal.properties.AxisTickPage.apply(), org.swtchart.ext.internal.properties.AxisPage.apply(), and org.swtchart.internal.series.Series.getPixelCoordinate().
IGrid org.swtchart.IAxis.getGrid | ( | ) |
Gets the grid.
The gird interval is identical with the position of axis tick marks. The horizontal grid is accessible from vertical axis, and the vertical grid is accessible from horizontal axis.
Implemented in org.swtchart.internal.axis.Axis.
Referenced by org.swtchart.ext.internal.properties.GridPage.apply(), and org.swtchart.ext.internal.properties.GridPage.selectInitialValues().
int org.swtchart.IAxis.getId | ( | ) |
Gets the axis id.
An axis id is automatically assigned when axis is created.
Implemented in org.swtchart.internal.axis.Axis.
Referenced by org.swtchart.ext.internal.properties.AxisTickPage.apply(), org.swtchart.ext.internal.properties.AxisPage.apply(), and org.swtchart.internal.series.SeriesSet.updateStackAndRiserData().
int org.swtchart.IAxis.getPixelCoordinate | ( | double | dataCoordinate | ) |
Gets the pixel coordinate corresponding to the given data coordinate.
dataCoordinate | the data coordinate |
Implemented in org.swtchart.internal.axis.Axis.
Referenced by org.swtchart.examples.advanced.DataToPixelConversionExample.createChart(), and org.swtchart.internal.series.Series.getPixelCoordinate().
Position org.swtchart.IAxis.getPosition | ( | ) |
Gets the axis position.
Implemented in org.swtchart.internal.axis.Axis.
Referenced by org.swtchart.ext.internal.properties.AxisPage.selectInitialValues().
Range org.swtchart.IAxis.getRange | ( | ) |
Gets the axis range.
Implemented in org.swtchart.internal.axis.Axis.
Referenced by org.swtchart.internal.series.SeriesSet.compressAllSeries(), and org.swtchart.ext.internal.properties.AxisPage.selectInitialValues().
IAxisTick org.swtchart.IAxis.getTick | ( | ) |
Gets the axis tick.
Implemented in org.swtchart.internal.axis.Axis.
Referenced by org.swtchart.ext.internal.properties.AxisTickPage.apply(), org.swtchart.examples.MultipleAxesExample.createChart(), org.swtchart.examples.AngledAxisTickLabelsExample.createChart(), and org.swtchart.ext.internal.properties.AxisTickPage.selectInitialValues().
ITitle org.swtchart.IAxis.getTitle | ( | ) |
Gets the axis title.
Implemented in org.swtchart.internal.axis.Axis.
Referenced by org.swtchart.ext.internal.properties.AxisPage.apply(), org.swtchart.examples.StepChartExample.createChart(), org.swtchart.examples.StackSeriesExample.createChart(), org.swtchart.examples.SeriesLabelExample.createChart(), org.swtchart.examples.ScatterChartExample.createChart(), org.swtchart.examples.OrientationExample.createChart(), org.swtchart.examples.MultipleAxesExample.createChart(), org.swtchart.examples.LogScaleExample.createChart(), org.swtchart.examples.LineChartExample.createChart(), org.swtchart.examples.LargeSeriesExample.createChart(), org.swtchart.examples.CategoryExample.createChart(), org.swtchart.examples.BarChartExample.createChart(), and org.swtchart.ext.internal.properties.AxisPage.selectInitialValues().
boolean org.swtchart.IAxis.isCategoryEnabled | ( | ) |
Gets the state indicating if category is enabled.
Implemented in org.swtchart.internal.axis.Axis.
Referenced by org.swtchart.internal.series.Series.getPixelCoordinate(), and org.swtchart.ext.internal.properties.AxisPage.selectInitialValues().
boolean org.swtchart.IAxis.isLogScaleEnabled | ( | ) |
Gets the state indicating if log scale is enabled.
Implemented in org.swtchart.internal.axis.Axis.
Referenced by org.swtchart.internal.series.SeriesSet.compressAllSeries(), org.swtchart.internal.series.Series.isValidStackSeries(), org.swtchart.ext.internal.properties.AxisPage.selectInitialValues(), and org.swtchart.internal.series.Series.setXAxisId().
void org.swtchart.IAxis.scrollDown | ( | ) |
Scrolls up the axis.
Implemented in org.swtchart.internal.axis.Axis.
void org.swtchart.IAxis.scrollUp | ( | ) |
Scrolls up the axis.
Implemented in org.swtchart.internal.axis.Axis.
void org.swtchart.IAxis.setCategorySeries | ( | String[] | series | ) |
Sets the category series.
In order to enable category series, enableCategoryAxis(true)
has to be invoked.
series | the category series |
Implemented in org.swtchart.internal.axis.Axis.
Referenced by org.swtchart.examples.StackSeriesExample.createChart(), org.swtchart.examples.CategoryExample.createChart(), org.swtchart.examples.AngledAxisTickLabelsExample.createChart(), and org.swtchart.examples.ext.InteractiveChartExample.createPartControl().
void org.swtchart.IAxis.setPosition | ( | Position | position | ) |
Sets the axis position.
position | the axis position |
Referenced by org.swtchart.ext.internal.properties.AxisPage.apply(), and org.swtchart.examples.MultipleAxesExample.createChart().
void org.swtchart.IAxis.setRange | ( | Range | range | ) |
Sets the axis range.
range | the axis range |
Implemented in org.swtchart.internal.axis.Axis.
Referenced by org.swtchart.ext.internal.properties.AxisPage.apply(), and org.swtchart.ext.InteractiveChart.setRange().
void org.swtchart.IAxis.zoomIn | ( | double | coordinate | ) |
Zooms in the axis at the given coordinate.
coordinate | the coordinate |
Implemented in org.swtchart.internal.axis.Axis.
void org.swtchart.IAxis.zoomIn | ( | ) |
Zooms in the axis.
Implemented in org.swtchart.internal.axis.Axis.
void org.swtchart.IAxis.zoomOut | ( | double | coordinate | ) |
Zooms out the axis at the given coordinate.
coordinate | the coordinate |
Implemented in org.swtchart.internal.axis.Axis.
void org.swtchart.IAxis.zoomOut | ( | ) |
Zooms out the axis.
Implemented in org.swtchart.internal.axis.Axis.