The wheel widget can be used to change values over a very large range in very small steps. Using the setMass member, it can be configured as a flywheel.
Definition at line 25 of file qwt_wheel.h.
Public Member Functions | |
QwtWheel (QWidget *parent=NULL) | |
virtual | ~QwtWheel () |
virtual void | setOrientation (Qt::Orientation) |
double | totalAngle () const |
double | viewAngle () const |
int | tickCnt () const |
int | internalBorder () const |
double | mass () const |
void | setTotalAngle (double angle) |
void | setTickCnt (int cnt) |
void | setViewAngle (double angle) |
void | setInternalBorder (int width) |
void | setMass (double val) |
void | setWheelWidth (int w) |
virtual QSize | sizeHint () const |
virtual QSize | minimumSizeHint () const |
Protected Member Functions | |
virtual void | resizeEvent (QResizeEvent *e) |
virtual void | paintEvent (QPaintEvent *e) |
void | layoutWheel (bool update=true) |
void | draw (QPainter *p, const QRect &update_rect) |
void | drawWheel (QPainter *p, const QRect &r) |
void | drawWheelBackground (QPainter *p, const QRect &r) |
void | setColorArray () |
virtual void | valueChange () |
virtual void | paletteChange (const QPalette &) |
virtual double | getValue (const QPoint &p) |
virtual void | getScrollMode (const QPoint &p, int &scrollMode, int &direction) |
|
Constructor.
Definition at line 51 of file qwt_wheel.cpp. References QwtAbstractSlider::setUpdateTime(). |
|
Destructor.
Definition at line 72 of file qwt_wheel.cpp. |
|
Redraw panel and wheel.
Definition at line 543 of file qwt_wheel.cpp. References drawWheel(). Referenced by paintEvent(). |
|
Redraw the wheel.
Definition at line 358 of file qwt_wheel.cpp. References drawWheelBackground(), QwtDoubleRange::maxValue(), QwtDoubleRange::minValue(), QwtAbstractSlider::orientation(), and QwtDoubleRange::value(). Referenced by draw(). |
|
Draw the Wheel's background gradient.
Definition at line 183 of file qwt_wheel.cpp. References QwtAbstractSlider::orientation(), and setColorArray(). Referenced by drawWheel(). |
|
Determine the scrolling mode and direction corresponding to a specified point.
Implements QwtAbstractSlider. Definition at line 575 of file qwt_wheel.cpp. |
|
Determine the value corresponding to a specified point.
Implements QwtAbstractSlider. Definition at line 473 of file qwt_wheel.cpp. References QwtDoubleRange::maxValue(), QwtDoubleRange::minValue(), and QwtAbstractSlider::orientation(). |
|
Recalculate the slider's geometry and layout based on.
Definition at line 512 of file qwt_wheel.cpp. Referenced by resizeEvent(), setInternalBorder(), setOrientation(), and setWheelWidth(). |
|
Reimplemented from QwtAbstractSlider. Definition at line 154 of file qwt_wheel.cpp. References QwtAbstractSlider::mass(). |
|
Return a minimum size hint.
Definition at line 621 of file qwt_wheel.cpp. References QwtAbstractSlider::orientation(). Referenced by sizeHint(). |
|
Qt Paint Event.
Definition at line 526 of file qwt_wheel.cpp. References draw(), and QwtPaintBuffer::painter(). |
|
Call update() when the palette changes.
Definition at line 633 of file qwt_wheel.cpp. |
|
Qt Resize Event.
Definition at line 503 of file qwt_wheel.cpp. References layoutWheel(). |
|
Set up the color array for the background pixmap.
Definition at line 82 of file qwt_wheel.cpp. Referenced by drawWheelBackground(). |
|
Set the internal border width of the wheel. The internal border must not be smaller than 1 and is limited in dependence on the wheel's size. Values outside the allowed range will be clipped. The internal border defaults to 2.
Definition at line 169 of file qwt_wheel.cpp. References layoutWheel(). |
|
Set the mass of the wheel. Assigning a mass turns the wheel into a flywheel.
Reimplemented from QwtAbstractSlider. Definition at line 591 of file qwt_wheel.cpp. References QwtAbstractSlider::setMass(). |
|
Set the wheel's orientation.
Definition at line 308 of file qwt_wheel.cpp. References layoutWheel(), and QwtAbstractSlider::orientation(). |
|
Adjust the number of grooves in the wheel's surface. The number of grooves is limited to 6 <= cnt <= 50. Values outside this range will be clipped. The default value is 10.
Definition at line 140 of file qwt_wheel.cpp. References qwtLim(). |
|
Set the total angle which the wheel can be turned. One full turn of the wheel corresponds to an angle of 360 degrees. A total angle of n*360 degrees means that the wheel has to be turned n times around its axis to get from the minimum value to the maximum value. The default setting of the total angle is 360 degrees.
Definition at line 290 of file qwt_wheel.cpp. References qwtLim(). |
|
Specify the visible portion of the wheel. You may use this function for fine-tuning the appearance of the wheel. The default value is 175 degrees. The value is limited from 10 to 175 degrees.
Definition at line 342 of file qwt_wheel.cpp. References qwtLim(). |
|
Set the width of the wheel. Corresponds to the wheel height for horizontal orientation, and the wheel width for vertical orientation.
Definition at line 603 of file qwt_wheel.cpp. References layoutWheel(). |
|
Definition at line 612 of file qwt_wheel.cpp. References minimumSizeHint(). |
|
Notify value change.
Reimplemented from QwtAbstractSlider. Definition at line 561 of file qwt_wheel.cpp. References QwtAbstractSlider::valueChange(). |