QwtScaleDiv Class Reference
A class representing a scale division. More...
#include <qwt_scale_div.h>
Public Types | |
| enum | TickType { NoTick = -1, MinorTick, MediumTick, MajorTick, NTickTypes } |
Public Member Functions | |
| QwtScaleDiv () | |
| QwtScaleDiv (const QwtDoubleInterval &, QwtValueList[NTickTypes]) | |
| QwtScaleDiv (double lowerBound, double upperBound, QwtValueList[NTickTypes]) | |
| int | operator== (const QwtScaleDiv &s) const |
| int | operator!= (const QwtScaleDiv &s) const |
| void | setInterval (double lowerBound, double upperBound) |
| void | setInterval (const QwtDoubleInterval &) |
| QwtDoubleInterval | interval () const |
| double | lowerBound () const |
| double | upperBound () const |
| double | range () const |
| bool | contains (double v) const |
| void | setTicks (int type, const QwtValueList &) |
| const QwtValueList & | ticks (int type) const |
| void | invalidate () |
| bool | isValid () const |
| void | invert () |
Detailed Description
A class representing a scale division.
A scale division consists of its limits and 3 list of tick values qualified as major, medium and minor ticks.
In most cases scale divisions are calculated by a QwtScaleEngine.
- See also:
- subDivideInto(), subDivide()
Member Enumeration Documentation
Scale tick types.
Constructor & Destructor Documentation
| QwtScaleDiv::QwtScaleDiv | ( | ) | [explicit] |
Construct an invalid QwtScaleDiv instance.
| QwtScaleDiv::QwtScaleDiv | ( | const QwtDoubleInterval & | interval, | |
| QwtValueList | ticks[NTickTypes] | |||
| ) | [explicit] |
Construct QwtScaleDiv instance.
- Parameters:
-
interval Interval ticks List of major, medium and minor ticks
| QwtScaleDiv::QwtScaleDiv | ( | double | lowerBound, | |
| double | upperBound, | |||
| QwtValueList | ticks[NTickTypes] | |||
| ) | [explicit] |
Construct QwtScaleDiv instance.
- Parameters:
-
lowerBound First interval limit upperBound Second interval limit ticks List of major, medium and minor ticks
Member Function Documentation
| bool QwtScaleDiv::contains | ( | double | value | ) | const |
Return if a value is between lowerBound() and upperBound()
- Parameters:
-
value Value
- Returns:
- true/false
| QwtDoubleInterval QwtScaleDiv::interval | ( | ) | const [inline] |
- Returns:
- lowerBound -> upperBound
| void QwtScaleDiv::invalidate | ( | ) |
Invalidate the scale division.
| void QwtScaleDiv::invert | ( | ) |
Invert the scale divison.
| bool QwtScaleDiv::isValid | ( | ) | const |
Check if the scale division is valid.
| double QwtScaleDiv::lowerBound | ( | ) | const [inline] |
- Returns:
- lower bound
- See also:
- upperBound()
| int QwtScaleDiv::operator!= | ( | const QwtScaleDiv & | s | ) | const |
Inequality.
- Returns:
- true if this instance is not equal to s
| int QwtScaleDiv::operator== | ( | const QwtScaleDiv & | other | ) | const |
Equality operator.
- Returns:
- true if this instance is equal to other
| double QwtScaleDiv::range | ( | ) | const [inline] |
- Returns:
- upperBound() - lowerBound()
| void QwtScaleDiv::setInterval | ( | const QwtDoubleInterval & | interval | ) |
Change the interval
- Parameters:
-
interval Interval
| void QwtScaleDiv::setInterval | ( | double | lowerBound, | |
| double | upperBound | |||
| ) | [inline] |
Change the interval
- Parameters:
-
lowerBound lower bound upperBound upper bound
| void QwtScaleDiv::setTicks | ( | int | type, | |
| const QwtValueList & | ticks | |||
| ) |
Assign ticks
- Parameters:
-
type MinorTick, MediumTick or MajorTick ticks Values of the tick positions
| const QwtValueList & QwtScaleDiv::ticks | ( | int | type | ) | const |
Return a list of ticks
- Parameters:
-
type MinorTick, MediumTick or MajorTick
| double QwtScaleDiv::upperBound | ( | ) | const [inline] |
- Returns:
- upper bound
- See also:
- lowerBound()
Generated on Wed Sep 2 18:37:27 2009 for Qwt User's Guide by
1.6.1