Rogue Wave Views 5.5.1 |
Rogue Wave Views |
Rogue Wave Views Documentation Home |
Class for computing the graduations of a scale. More...
#include <ilviews/charts/scaledis.h>
Public Member Functions | |
IlvConstantScaleStepsUpdater (IlvSingleScaleDisplayer *scale, IlDouble stepUnit, IlDouble subStepUnit=0.) | |
Constructor. | |
IlvConstantScaleStepsUpdater (IlvSingleScaleDisplayer *scale, IlUInt stepsCount, IlUInt subStepsCount=0) | |
Constructor. | |
IlvConstantScaleStepsUpdater (IlvSingleScaleDisplayer *scale) | |
Constructor. | |
virtual IlBoolean | checkRange (IlvCoordInterval &range) const |
Checks whether an interval is valid with respect to the step definition. | |
void | fixStepsCount (IlUInt stepsCount, IlUInt subStepsCount) |
Sets the number of steps and the number of substeps between two steps. | |
void | fixStepUnit (IlDouble stepUnit, IlDouble subStepUnit) |
Sets the step unit and the substep unit. | |
IlDouble | getFirstStepData () const |
Returns the data value associated with the first major step. | |
IlDouble | getLastStepData () const |
Returns the data value associated with the last major step. | |
IlUInt | getStepsCount () const |
Returns the number of major steps. | |
virtual void | getStepSubStepValues (const IlvProjectorArea &area, IlUInt &stepsCount, IlDouble *&stepValues, IlUInt &subStepsCount, IlDouble *&subStepValues) const |
Computes and returns the step and substep values for the associated scale. | |
IlDouble | getStepUnit () const |
Returns the step unit. | |
IlUInt | getSubStepsCount () const |
Returns the number of minor steps between two major steps. | |
IlDouble | getSubStepUnit () const |
Returns the substep unit. | |
IlBoolean | isFirstStepDataDefined () const |
Indicates whether a data value is associated with the first major step. | |
IlBoolean | isLastStepDataDefined () const |
Indicates whether a data value is associated with the last major step. | |
void | setFirstStepData (IlDouble value) |
Sets the data value associated with the first major step. | |
void | setLastStepData (IlDouble value) |
Sets the data value associated with the last major step. |
Class for computing the graduations of a scale.
Library: ilvcharts
IlvConstantScaleStepsUpdater
is a subclass of IlvScaleStepsUpdater
that allows you to compute steps and substeps having a fixed spacing.
IlvScaleStepsUpdater
, IlvSingleScaleDisplayer
. IlvConstantScaleStepsUpdater::IlvConstantScaleStepsUpdater | ( | IlvSingleScaleDisplayer * | scale | ) |
Constructor.
Initializes a new IlvConstantScaleStepsUpdater
object.
scale | The scale associated with the current scale steps updater. |
IlvConstantScaleStepsUpdater::IlvConstantScaleStepsUpdater | ( | IlvSingleScaleDisplayer * | scale, | |
IlUInt | stepsCount, | |||
IlUInt | subStepsCount = 0 | |||
) |
Constructor.
Initializes a new IlvConstantScaleStepsUpdater
object with a fixed number of steps and substeps.
scale | The scale associated with the current scale steps updater. | |
stepsCount | The number of steps defined for the scale scale . | |
subStepsCount | The number of substeps defined for the scale scale. |
IlvConstantScaleStepsUpdater::IlvConstantScaleStepsUpdater | ( | IlvSingleScaleDisplayer * | scale, | |
IlDouble | stepUnit, | |||
IlDouble | subStepUnit = 0. | |||
) |
Constructor.
Initializes a new IlvConstantScaleStepsUpdater
object with fixed step and substep units.
scale | The scale associated with the current scale steps updater. | |
stepUnit | The step unit defined for the scale scale. | |
subStepUnit | The substep unit defined for the scale scale. |
virtual IlBoolean IlvConstantScaleStepsUpdater::checkRange | ( | IlvCoordInterval & | range | ) | const [virtual] |
Checks whether an interval is valid with respect to the step definition.
Called whenever the range of the coordinate associated with the current scale is modified. With this method, you can modify the interval range so that it becomes consistent with the steps definition. The default implementation simply returns IlTrue
.
range | The range to check. |
IlFalse
if the range was not correct and had to be modified, and IlTrue
otherwise. Reimplemented from IlvScaleStepsUpdater.
Sets the number of steps and the number of substeps between two steps.
Allows you to define the step and substep values by specifying the exact number of steps and substeps. The resulting step unit will depend on the coordinate range shown by the associated scale.
stepsCount | The fixed number of steps. This number must be at least equal to 1 . | |
subStepsCount | The fixed number of substeps between two steps. |
fixStepUnit
. Sets the step unit and the substep unit.
Allows you to define the steps and substeps values by specifying the step and the substep unit. The number of resulting steps and substeps will depend on the coordinate range shown by the associated scale.
stepUnit | The step unit. This value must be positive. | |
subStepUnit | The substep unit. This value must be positive and less than stepUnit. A value equal to 0 means that there are no substeps. |
fixStepsCount
. IlDouble IlvConstantScaleStepsUpdater::getFirstStepData | ( | ) | const |
Returns the data value associated with the first major step.
IlDouble IlvConstantScaleStepsUpdater::getLastStepData | ( | ) | const |
Returns the data value associated with the last major step.
IlUInt IlvConstantScaleStepsUpdater::getStepsCount | ( | ) | const |
Returns the number of major steps.
virtual void IlvConstantScaleStepsUpdater::getStepSubStepValues | ( | const IlvProjectorArea & | area, | |
IlUInt & | stepsCount, | |||
IlDouble *& | stepValues, | |||
IlUInt & | subStepsCount, | |||
IlDouble *& | subStepValues | |||
) | const [virtual] |
Computes and returns the step and substep values for the associated scale.
area | The data area definition. This data area definition can be retrieved with the IlvChartGraphic::getProjectorArea method. | |
stepsCount | Returns the number of major steps. | |
stepValues | Returns the values associated with the major steps. | |
subStepsCount | Returns the number of minor steps. | |
subStepValues | Returns the values associated with the minor steps. |
Implements IlvScaleStepsUpdater.
Reimplemented in IlvAutoScaleStepsUpdater.
IlDouble IlvConstantScaleStepsUpdater::getStepUnit | ( | ) | const |
IlUInt IlvConstantScaleStepsUpdater::getSubStepsCount | ( | ) | const |
Returns the number of minor steps between two major steps.
IlDouble IlvConstantScaleStepsUpdater::getSubStepUnit | ( | ) | const |
Returns the substep unit.
IlBoolean IlvConstantScaleStepsUpdater::isFirstStepDataDefined | ( | ) | const |
Indicates whether a data value is associated with the first major step.
IlTrue
if an associated value exists and IlFalse
otherwise. IlBoolean IlvConstantScaleStepsUpdater::isLastStepDataDefined | ( | ) | const |
Indicates whether a data value is associated with the last major step.
IlTrue
if an associated value exists and IlFalse
otherwise. void IlvConstantScaleStepsUpdater::setFirstStepData | ( | IlDouble | value | ) |
Sets the data value associated with the first major step.
This method lets you define which value should be associated with the first major step of the scale. If this data is not defined, the first step will be drawn for the minimum value of the coordinate range represented by the associated scale.
value | The value for the first major step. |
void IlvConstantScaleStepsUpdater::setLastStepData | ( | IlDouble | value | ) |
Sets the data value associated with the last major step.
This method lets you define which value should be associated with the last major step of the scale. If this data is not defined, the last step will be drawn for the maximum value of the coordinate range represented by the associated scale.
value | The value for the last major step. |
© Copyright 2012, Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave is a registered trademark of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.