Classes | Public Member Functions | Protected Member Functions | Private Attributes
QwtArrowButton Class Reference

Arrow Button. More...

#include <qwt_arrow_button.h>

List of all members.

Classes

class  PrivateData

Public Member Functions

Qt::ArrowType arrowType () const
 The direction of the arrows.
virtual QSize minimumSizeHint () const
 Return a minimum size hint.
int num () const
 The number of arrows.
 QwtArrowButton (int num, Qt::ArrowType, QWidget *parent=NULL)
virtual QSize sizeHint () const
virtual ~QwtArrowButton ()
 Destructor.

Protected Member Functions

virtual QSize arrowSize (Qt::ArrowType, const QSize &boundingSize) const
virtual void drawArrow (QPainter *, const QRect &, Qt::ArrowType) const
virtual void drawButtonLabel (QPainter *p)
 Draw the button label.
virtual void keyPressEvent (QKeyEvent *)
 autoRepeat for the space keys
virtual QRect labelRect () const
virtual void paintEvent (QPaintEvent *event)

Private Attributes

PrivateDatad_data

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.

Definition at line 23 of file qwt_arrow_button.h.


Constructor & Destructor Documentation

QwtArrowButton::QwtArrowButton ( int  num,
Qt::ArrowType  arrowType,
QWidget *  parent = NULL 
) [explicit]
Parameters:
numNumber of arrows
arrowTypesee Qt::ArrowType in the Qt docs.
parentParent widget

Definition at line 55 of file qwt_arrow_button.cpp.

Destructor.

Definition at line 80 of file qwt_arrow_button.cpp.


Member Function Documentation

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

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

Parameters:
arrowTypeArrow type
boundingSizeBounding size
Returns:
Size of the arrow

Definition at line 297 of file qwt_arrow_button.cpp.

Qt::ArrowType QwtArrowButton::arrowType ( ) const

The direction of the arrows.

Definition at line 89 of file qwt_arrow_button.cpp.

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

Draw an arrow int a bounding rectangle

Parameters:
painterPainter
rRectangle where to paint the arrow
arrowTypeArrow type

Definition at line 216 of file qwt_arrow_button.cpp.

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

Draw the button label.

Parameters:
painterPainter
See also:
The Qt Manual for QPushButton

Definition at line 144 of file qwt_arrow_button.cpp.

void QwtArrowButton::keyPressEvent ( QKeyEvent *  event) [protected, virtual]

autoRepeat for the space keys

Definition at line 327 of file qwt_arrow_button.cpp.

QRect QwtArrowButton::labelRect ( ) const [protected, virtual]
Returns:
the bounding rectangle for the label

Definition at line 105 of file qwt_arrow_button.cpp.

QSize QwtArrowButton::minimumSizeHint ( ) const [virtual]

Return a minimum size hint.

Definition at line 269 of file qwt_arrow_button.cpp.

int QwtArrowButton::num ( ) const

The number of arrows.

Definition at line 97 of file qwt_arrow_button.cpp.

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

Paint event handler

Parameters:
eventPaint event

Definition at line 131 of file qwt_arrow_button.cpp.

QSize QwtArrowButton::sizeHint ( ) const [virtual]
Returns:
a size hint

Definition at line 260 of file qwt_arrow_button.cpp.


Member Data Documentation

Definition at line 48 of file qwt_arrow_button.h.


The documentation for this class was generated from the following files:


plotjuggler
Author(s): Davide Faconti
autogenerated on Fri Sep 1 2017 02:41:57