QwtKnob(3) | Qwt User's Guide | QwtKnob(3) |
NAME¶
QwtKnob -
SYNOPSIS¶
#include <qwt_knob.h>
Inherits QwtAbstractSlider, and QwtAbstractScale.
Public Types¶
enum Symbol { Line, Dot }
Public Member Functions¶
QwtKnob (QWidget *parent=NULL)
virtual ~QwtKnob ()
int borderWidth () const
int knobWidth () const
virtual QSize minimumSizeHint () const
const QwtRoundScaleDraw * scaleDraw () const
QwtRoundScaleDraw * scaleDraw ()
void setBorderWidth (int bw)
void setKnobWidth (int w)
void setScaleDraw (QwtRoundScaleDraw *)
void setSymbol (Symbol)
void setTotalAngle (double angle)
virtual QSize sizeHint () const
Symbol symbol () const
double totalAngle () const
Protected Member Functions¶
void draw (QPainter *p, const QRect &ur)
void drawKnob (QPainter *p, const QRect &r)
void drawMarker (QPainter *p, double arc, const QColor &c)
virtual void paintEvent (QPaintEvent *e)
virtual void resizeEvent (QResizeEvent *e)
Additional Inherited Members¶
Detailed Description¶
The Knob Widget.
The QwtKnob widget imitates look and behaviour of a volume knob on a radio. It contains a scale around the knob which is set up automatically or can be configured manually (see QwtAbstractScale). Automatic scrolling is enabled when the user presses a mouse button on the scale. For a description of signals, slots and other members, see QwtAbstractSlider.
See also:
Member Enumeration Documentation¶
enum QwtKnob::Symbol¶
Symbol
See also:
Constructor & Destructor Documentation¶
QwtKnob::QwtKnob (QWidget *parent = NULL) [explicit]¶
Constructor
Parameters:
Member Function Documentation¶
void QwtKnob::draw (QPainter *painter, const QRect &rect) [protected]¶
Repaint the knob
Parameters:
rect Update rectangle
void QwtKnob::drawKnob (QPainter *painter, const QRect &r) [protected]¶
Draw the knob. Parameters:
r Bounding rectangle of the knob (without scale)
void QwtKnob::drawMarker (QPainter *p, doublearc, const QColor &c) [protected]¶
Draw the marker at the knob's front. Parameters:
arc Angle of the marker
c Marker color
QSize QwtKnob::minimumSizeHint () const [virtual]¶
Return a minimum size hint. Warning:
void QwtKnob::paintEvent (QPaintEvent *e) [protected], [virtual]¶
Repaint the knob
Parameters:
void QwtKnob::resizeEvent (QResizeEvent *e) [protected], [virtual]¶
Qt Resize Event
const QwtRoundScaleDraw * QwtKnob::scaleDraw () const¶
Returns:
See also:
QwtRoundScaleDraw * QwtKnob::scaleDraw ()¶
Returns:
See also:
void QwtKnob::setBorderWidth (intbw)¶
Set the knob's border width. Parameters:
void QwtKnob::setKnobWidth (intw)¶
Change the knob's width. The specified width must be >= 5, or it will be clipped.
Parameters:
void QwtKnob::setScaleDraw (QwtRoundScaleDraw *scaleDraw)¶
Change the scale draw of the knob
For changing the labels of the scales, it is necessary to derive from QwtRoundScaleDraw and overload QwtRoundScaleDraw::label().
See also:
void QwtKnob::setSymbol (QwtKnob::Symbols)¶
Set the symbol of the knob. See also:
void QwtKnob::setTotalAngle (doubleangle)¶
Set the total angle by which the knob can be turned. Parameters:
The default angle is 270 degrees. It is possible to specify an angle of more than 360 degrees so that the knob can be turned several times around its axis.
QSize QwtKnob::sizeHint () const [virtual]¶
Returns:
QwtKnob::Symbol QwtKnob::symbol () const¶
Returns:
See also:
Author¶
Generated automatically by Doxygen for Qwt User's Guide from the source code.
Tue Nov 20 2012 | Version 5.2.3 |