Qwt Programmer's Manual

QwtSlider


NAME

QwtSlider - The Slider Widget

SYNOPSIS

#include <qwt_slider.h>

DESCRIPTION

QwtSlider is a slider widget which operates on an interval of type double. QwtSlider supports different layouts as well as a scale.

INHERITED CLASSES

QwtSliderBase, QwtScaleIf

PUBLIC MEMBERS

QwtSlider
Constructor
~QwtSlider
Destructor
setThumbLength
Set the length of the slider's thumb
setThumbWidth
Set the length of the slider's thumb
setBorderWidth
Set the border width
setMargins
Set the internal border distance

SEE ALSO

QwtSliderBase and QwtScaleIf for the descriptions of the inherited members.

MEMBER FUNCTION DESCRIPTION


QwtSlider::QwtSlider

Constructor

Syntax:

QwtSlider::QwtSlider(QWidget *parent, const char *name, Orientation orient = Horizontal, ScalePos scalePos = None, int bgStyle = BgTrough)

Parameters

QWidget *parent
parent widget
const char *name
The Widget's name. Default = 0.
Orientation Orient
Orientation of the slider. Can be QwtSlider::Horizontal or QwtSlider::Vertical. Defaults to Horizontal.
ScalePos scalePos
Position of the scale. Can be QwtSlider::None, QwtSlider::Left, QwtSlider::Right, QwtSlider::Top, or QwtSlider::Bottom. Defaults to QwtSlider::None.
int bgStyle
Background style. QwtSlider::BgTrough draws the slider button in a trough, QwtSlider::BgSlot draws a slot underneath the button. An or-combination of both may also be used. The default is QwtSlider::BgTrough.

QwtSlider::~QwtSlider

Destructor

Syntax

QwtSlider::~QwtSlider()

QwtSlider::setBorderWidth

Change the slider's border width

Syntax

void QwtSlider::setBorderWidth(int bd)

Parameters

int bd
border width

QwtSlider::setThumbLength

Set the slider's thumb length

Syntax

void QwtSlider::setThumbLength(int l)

Parameters

int l
new length

QwtSlider::setThumbWidth

Change the width of the thumb

Syntax

void QwtSlider::setThumbWidth(int w)

Parameters

int w
new width

QwtSlider::setMargins

Set distances between the widget's border and internals.

Syntax

void QwtSlider::setMargins(int hor, int vert)

Parameters

int hor, int vert
Margins

QwtSlider::sizeHint

Return a recommended size

Syntax

QSize QwtSlider::sizeHint() const

Note

The return value of sizeHint() depends on the font and the scale.
Qwt Widget Library 02/04/98