QwtArrowButton(3)
πΈ NAME πΈ
QwtArrowButton β that's the whole name bestie, the manpage literally just drops it and dips π but it's from the Qwt User's Guide, section 3, and we're gonna get into it.
β¨ SYNOPSIS β¨
First things first, you gotta pull it in:
#include <qwt_arrow_button.h>
π Public Member Functions π
QwtArrowButton (int num, Qt::ArrowType, QWidget *parent=NULL)
virtual ~QwtArrowButton ()
Qt::ArrowType arrowType () const
virtual QSize minimumSizeHint () const
int num () const
virtual QSize sizeHint () const
π 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)
virtual void keyPressEvent (QKeyEvent *)
virtual QRect labelRect () const
virtual void paintEvent (QPaintEvent *event)
π¦ Detailed Description π¦
Okay so, Arrow Button. Periodt.
It's a push button, right? But instead of just vibes and a label, it's got one or more filled triangles chillin' on its front. π
And the range? An Arrow button can have 1 to 3 arrows in a row, and they can point up, down, left or right. That's it, that's the whole aesthetic. No cap.
π Constructor & Destructor Documentation π
π QwtArrowButton::QwtArrowButton (int num, Qt::ArrowType arrowType, QWidget *parent = NULL) [explicit] π
The glow-up moment where your button is born, bestie. It's explicit, so no sneaky implicit conversions, we don't do that here. π
Parameters:
numβ Number of arrowsarrowTypeβ seeQt::ArowTypein the Qt docs.parentβ Parent widget
Not me leaving the Qt::ArowType spelling exactly as written, iykyk β that's how the page says it, so that's how it stays. π
π 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 rect of a given size. Literally math-ing out how big the little triangle gets to be inside the space it's given. β¨
Parameters:
arrowTypeβ Arrow typeboundingSizeβ Bounding size
Returns:
- Size of the arrow
π₯ void QwtArrowButton::drawArrow (QPainter *painter, const QRect &r, Qt::ArrowType arrowType) const [protected], [virtual] π₯
Draw an arrow int a bounding rect. (Yes, "int" β iconic typo behavior, I am not touching it, that's the original's main character energy. π)
Parameters:
painterβ Painterrβ Rectangle where to paint the arrowarrowTypeβ Arrow type
πΈ void QwtArrowButton::drawButtonLabel (QPainter *painter) [protected], [virtual] πΈ
Draw the button label.
Parameters:
painterβ Painter
See also:
- The Qt Manual on
QPushButton
Like, if you wanna know how the label actually goes down, the Qt Manual on QPushButton is your girl. Go look. π
π¦ QRect QwtArrowButton::labelRect () const [protected], [virtual] π¦
Returns:
- the bounding rect for the label
π void QwtArrowButton::paintEvent (QPaintEvent *event) [protected], [virtual] π
Paint event handler. The moment the button gets told to show up and show out. β¨
Parameters:
eventβ Paint event
β QSize QwtArrowButton::sizeHint () const [virtual] β
Returns:
- a size hint
Quick lil note bestie: keyPressEvent (QKeyEvent *) is listed up there in the Protected Member Functions, but the page doesn't give it its own little section. Just so you're not out here searching for docs that aren't there. π«Ά
π Author π
Generated automatically by Doxygen for Qwt User's Guide from the source code. So nobody hand-wrote this, the robot did it, and honestly? It ate. π
And that's the whole page, bestie! π This was Version 5.2.3, dated Tue Nov 20 2012 β a whole vintage era, and we're still obsessed. Byeeee, go build your cute lil triangle button! π¦β¨π
π¦ where this page comes from
- epel 9: qwt5-qt5-devel 5.2.3a-12.20210522gita2b11e3.el9 Β· LGPLv2+ with exceptions
- fedora 43: qwt5-qt5-devel 5.2.3a-22.20210522gita2b11e3.fc43 Β· LGPL-2.1-or-later WITH Qwt-exception-1.0
- fedora 43: qwt5-qt5-devel 5.2.3a-22.20210522gita2b11e3.fc43 Β· LGPL-2.1-or-later WITH Qwt-exception-1.0
- fedora 44: qwt5-qt5-devel 5.2.3a-23.20210522gita2b11e3.fc44 Β· LGPL-2.1-or-later WITH Qwt-exception-1.0
- fedora 44: qwt5-qt5-devel 5.2.3a-23.20210522gita2b11e3.fc44 Β· LGPL-2.1-or-later WITH Qwt-exception-1.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms