The NChartAxisPositionCoord class provides methods to control the position of the chart axis. More...
Public Member Functions | |
NChartAxisPositionCoordValue | getValueType () |
Type of the coordinate value. More... | |
void | setValueType (NChartAxisPositionCoordValue valueType) |
For details see getValueType(). | |
double | getValue () |
Value of the coordinate. More... | |
void | setValue (double value) |
For details see getValue(). | |
boolean | getHostsOnSAxis () |
Flag determining if the position is calculated according to the secondary axis (true) or not (false). | |
void | setHostsOnSAxis (boolean hostsOnSAxis) |
For details see getValue(). | |
Detailed Description
The NChartAxisPositionCoord class provides methods to control the position of the chart axis.
Each Cartesian system axis has properties for X, Y and Z coordinates, but for every particular axis only two of them are meaningful. For example, for the X-Axis only Y and Z take effect, for Y-Axis only X and Z and so on. Each coordinate is associated with particular direction: X-coordinate is tied to the horizontal direction, Y to the vertical and Z to the depth. According to valueType, value and hostsOnSAxis of the coordinate, actual position in the corresponding direction is determined.
For example, to place Y-Axis so, that it intersects X-Axis in the value 10, use the following code:
chartView.getChart().getCartesianSystem().getYAxis().getPositionX().setValue(10.0);
If you need Y-Axis to intersect SX-Axis in the value 10 instead, add the following:
chartView.getChart().getCartesianSystem().getYAxis().getPositionX().setHostsOnSAxis(true);
The next code line added to the previous settings will make Y-Axis to intersect SX-Axis in its maximal value:
chartView.getChart().getCartesianSystem().getYAxis().getPositionX().setValueType(NChartAxisPositionCoordValue.Maximum);
Member Function Documentation
|
inline |
Value of the coordinate.
The default value is 0.
This property takes effect if valueType is set to NChartAxisPositionCoordValue.Custom
only. If some value is assigned to this property, valueType is set to NChartAxisPositionCoordValue.Custom
automatically.
|
inline |
Type of the coordinate value.
If this property is set to NChartAxisPositionCoordValue.Custom
, position is calculated based on value. If NChartAxisPositionCoordValue.Minimum
or NChartAxisPositionCoordValue.Maximum
is set, position is calculated based on the corresponding axis' minimum or maximum respectively. The axis for the coordinate is chosen according to the actual property NChartAxisPositionCoord
is assigned to and hostsOnSAxis.
- See also
- NChartAxisPositionCoordValue