QwtArrowButton (3) - Linux Manuals


QwtArrowButton -

Arrow Button.


#include <qwt_arrow_button.h>

Inherits QPushButton.

Public Member Functions

QwtArrowButton (int num, Qt::ArrowType, QWidget *parent=NULL)

virtual ~QwtArrowButton ()
Qt::ArrowType arrowType () const
The direction of the arrows.
int num () const
The number of arrows.
virtual QSize sizeHint () const

virtual QSize minimumSizeHint () const
Return a minimum size hint.

Protected Member Functions

virtual void paintEvent (QPaintEvent *event)

virtual void drawButtonLabel (QPainter *p)
Draw the button label.
virtual void drawArrow (QPainter *, const QRect &, Qt::ArrowType) const

virtual QRect labelRect () const

virtual QSize arrowSize (Qt::ArrowType, const QSize &boundingSize) const

virtual void keyPressEvent (QKeyEvent *)
autoRepeat for the space keys

Detailed Description

Arrow Button.

A push button with one or more filled triangles on its front. An Arrow button can have 1 to 3 arrows in a row, pointing up, down, left or right.

Constructor & Destructor Documentation

QwtArrowButton::QwtArrowButton (intnum, Qt::ArrowTypearrowType, QWidget *parent = NULL) [explicit]


num Number of arrows
arrowType see Qt::ArrowType in the Qt docs.
parent Parent widget

Member Function Documentation

QSize QwtArrowButton::arrowSize (Qt::ArrowTypearrowType, const QSize &boundingSize) const [protected], [virtual]

Calculate the size for a arrow that fits into a rectangle of a given size


arrowType Arrow type
boundingSize Bounding size


Size of the arrow

void QwtArrowButton::drawArrow (QPainter *painter, const QRect &r, Qt::ArrowTypearrowType) const [protected], [virtual]

Draw an arrow int a bounding rectangle


painter Painter
r Rectangle where to paint the arrow
arrowType Arrow type

void QwtArrowButton::drawButtonLabel (QPainter *painter) [protected], [virtual]

Draw the button label.


painter Painter

See Also:

The Qt Manual for QPushButton

QRect QwtArrowButton::labelRect () const [protected], [virtual]


the bounding rectangle for the label

void QwtArrowButton::paintEvent (QPaintEvent *event) [protected], [virtual]

Paint event handler


event Paint event

QSize QwtArrowButton::sizeHint () const [virtual]


a size hint


Generated automatically by Doxygen for Qwt User's Guide from the source code.