QwtDialNeedle is a pointer that indicates a value by pointing to a specific direction.
Qwt is missing a set of good looking needles. Contributions are very welcome.
Definition at line 31 of file qwt_dial_needle.h.
Public Member Functions | |
QwtDialNeedle () | |
virtual | ~QwtDialNeedle () |
virtual void | draw (QPainter *painter, const QPoint ¢er, int length, double direction, QPalette::ColorGroup cg=QPalette::Active) const =0 |
virtual void | setPalette (const QPalette &) |
const QPalette & | palette () const |
Static Protected Member Functions | |
static void | drawKnob (QPainter *, const QPoint &pos, int width, const QBrush &, bool sunken) |
QwtDialNeedle::QwtDialNeedle | ( | ) |
QwtDialNeedle::~QwtDialNeedle | ( | ) | [virtual] |
virtual void QwtDialNeedle::draw | ( | QPainter * | painter, | |
const QPoint & | center, | |||
int | length, | |||
double | direction, | |||
QPalette::ColorGroup | cg = QPalette::Active | |||
) | const [pure virtual] |
Draw the needle
painter | Painter | |
center | Center of the dial, start position for the needle | |
length | Length of the needle | |
direction | Direction of the needle, in degrees counter clockwise | |
cg | Color group, used for painting |
Implemented in QwtDialSimpleNeedle, QwtCompassMagnetNeedle, and QwtCompassWindArrow.
Referenced by QwtAnalogClock::drawHand().
void QwtDialNeedle::setPalette | ( | const QPalette & | palette | ) | [virtual] |
Sets the palette for the needle.
palette | New Palette |
Definition at line 40 of file qwt_dial_needle.cpp.
Referenced by QwtCompassMagnetNeedle::QwtCompassMagnetNeedle(), QwtCompassWindArrow::QwtCompassWindArrow(), and QwtDialSimpleNeedle::QwtDialSimpleNeedle().
const QPalette & QwtDialNeedle::palette | ( | ) | const |
Definition at line 48 of file qwt_dial_needle.cpp.
Referenced by QwtCompassWindArrow::draw(), QwtCompassMagnetNeedle::draw(), QwtDialSimpleNeedle::draw(), QwtCompassMagnetNeedle::QwtCompassMagnetNeedle(), QwtCompassWindArrow::QwtCompassWindArrow(), and QwtDialSimpleNeedle::QwtDialSimpleNeedle().
void QwtDialNeedle::drawKnob | ( | QPainter * | painter, | |
const QPoint & | pos, | |||
int | width, | |||
const QBrush & | brush, | |||
bool | sunken | |||
) | [static, protected] |
Draw the knob.
Definition at line 54 of file qwt_dial_needle.cpp.
Referenced by QwtDialSimpleNeedle::drawArrowNeedle(), QwtDialSimpleNeedle::drawRayNeedle(), and QwtCompassMagnetNeedle::drawThinNeedle().