|
QWT API (中文) 7.3.0
Qt绘图库 - 中文API文档
|
Arrow Button 更多...
#include <qwt_arrow_button.h>
类 | |
| class | PrivateData |
Public 成员函数 | |
| QwtArrowButton (int num, Qt::ArrowType, QWidget *parent=nullptr) | |
| Constructor | |
| Qt::ArrowType | arrowType () const |
| Get the direction of the arrows | |
| int | num () const |
| Get the number of arrows | |
| virtual QSize | sizeHint () const override |
| Get a size hint for the button | |
| virtual QSize | minimumSizeHint () const override |
| Get a minimum size hint for the button | |
Protected 成员函数 | |
| virtual void | paintEvent (QPaintEvent *) override |
| Paint event handler | |
| virtual void | keyPressEvent (QKeyEvent *) override |
| autoRepeat for the space keys | |
| virtual void | drawButtonLabel (QPainter *) |
| Draw the button label | |
| virtual void | drawArrow (QPainter *, const QRect &, Qt::ArrowType) const |
| Draw an arrow int a bounding rectangle | |
| virtual QRect | labelRect () const |
| virtual QSize | arrowSize (Qt::ArrowType, const QSize &boundingSize) const |
| Calculate the size for a arrow that fits into a rectangle of a given size | |
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.
|
explicit |
Constructor
| [in] | num | Number of arrows (1-3) |
| [in] | arrowType | Direction of arrows (see Qt::ArrowType) |
| [in] | parent | Parent widget |
Destructor
|
protectedvirtual |
Calculate the size for a arrow that fits into a rectangle of a given size
| arrowType | Arrow type |
| boundingSize | Bounding size |
| Qt::ArrowType QwtArrowButton::arrowType | ( | ) | const |
Get the direction of the arrows
|
protectedvirtual |
Draw an arrow int a bounding rectangle
| painter | Painter |
| r | Rectangle where to paint the arrow |
| arrowType | Arrow type |
|
protectedvirtual |
Draw the button label
| painter | Painter |
|
protectedvirtual |
|
overridevirtual |
Get a minimum size hint for the button
| int QwtArrowButton::num | ( | ) | const |
Get the number of arrows
|
overrideprotectedvirtual |
Paint event handler
| event | Paint event |
|
overridevirtual |
Get a size hint for the button