KToolBarPopupAction
#include <KToolBarPopupAction>

Properties | |
QToolButton::ToolButtonPopupMode | popupMode |
![]() | |
autoRepeat | |
checkable | |
checked | |
enabled | |
font | |
icon | |
iconText | |
iconVisibleInMenu | |
menuRole | |
priority | |
shortcut | |
shortcutContext | |
shortcutVisibleInContextMenu | |
statusTip | |
text | |
toolTip | |
visible | |
whatsThis | |
![]() | |
objectName | |
Additional Inherited Members | |
![]() | |
enum | ActionEvent |
enum | MenuRole |
enum | Priority |
![]() | |
QMetaObject::Connection | connect (const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type) |
QMetaObject::Connection | connect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method, Qt::ConnectionType type) |
QMetaObject::Connection | connect (const QObject *sender, PointerToMemberFunction signal, const QObject *context, Functor functor, Qt::ConnectionType type) |
QMetaObject::Connection | connect (const QObject *sender, PointerToMemberFunction signal, const QObject *receiver, PointerToMemberFunction method, Qt::ConnectionType type) |
QMetaObject::Connection | connect (const QObject *sender, PointerToMemberFunction signal, Functor functor) |
bool | disconnect (const QMetaObject::Connection &connection) |
bool | disconnect (const QObject *sender, const char *signal, const QObject *receiver, const char *method) |
bool | disconnect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method) |
bool | disconnect (const QObject *sender, PointerToMemberFunction signal, const QObject *receiver, PointerToMemberFunction method) |
QString | tr (const char *sourceText, const char *disambiguation, int n) |
QString | trUtf8 (const char *sourceText, const char *disambiguation, int n) |
![]() | |
AboutQtRole | |
AboutRole | |
ApplicationSpecificRole | |
HighPriority | |
Hover | |
LowPriority | |
NormalPriority | |
NoRole | |
PreferencesRole | |
QuitRole | |
TextHeuristicRole | |
Trigger | |
![]() | |
typedef | QObjectList |
![]() | |
QList< QWidget * > | createdWidgets () const const |
virtual void | deleteWidget (QWidget *widget) |
virtual bool | event (QEvent *event) override |
virtual bool | eventFilter (QObject *obj, QEvent *event) override |
![]() | |
virtual void | childEvent (QChildEvent *event) |
virtual void | connectNotify (const QMetaMethod &signal) |
virtual void | customEvent (QEvent *event) |
virtual void | disconnectNotify (const QMetaMethod &signal) |
bool | isSignalConnected (const QMetaMethod &signal) const const |
int | receivers (const char *signal) const const |
QObject * | sender () const const |
int | senderSignalIndex () const const |
virtual void | timerEvent (QTimerEvent *event) |
Detailed Description
This action is a normal action everywhere, except in a toolbar where it also has a popupmenu (optionally delayed). This action is designed for history actions (back/forward, undo/redo) and for any other action that has more detail in a toolbar than in a menu (e.g. tool chooser with "Other" leading to a dialog...).
In contrast to KActionMenu, this action is a simple menuitem when plugged into a menu, and has a popup only in a toolbar.
Use cases include Back/Forward, and Undo/Redo. Simple click is what's most commonly used, and enough for menus, but in toolbars there is also an optional popup to go back N steps or undo N steps.
Definition at line 43 of file ktoolbarpopupaction.h.
Constructor & Destructor Documentation
◆ KToolBarPopupAction()
KToolBarPopupAction::KToolBarPopupAction | ( | const QIcon & | icon, |
const QString & | text, | ||
QObject * | parent | ||
) |
Create a KToolBarPopupAction, with a text, an icon, a parent and a name.
- Parameters
-
icon The icon to display. text The text that will be displayed. parent This action's parent.
Definition at line 33 of file ktoolbarpopupaction.cpp.
◆ ~KToolBarPopupAction()
|
override |
Destroys the toolbar popup action.
Definition at line 42 of file ktoolbarpopupaction.cpp.
Member Function Documentation
◆ createWidget()
Reimplemented from QWidgetAction.
Reimplemented from QWidgetAction.
Definition at line 47 of file ktoolbarpopupaction.cpp.
◆ popupMode()
QToolButton::ToolButtonPopupMode KToolBarPopupAction::popupMode | ( | ) | const |
◆ setPopupMode()
void KToolBarPopupAction::setPopupMode | ( | QToolButton::ToolButtonPopupMode | popupMode | ) |
Determines the popup mode of the toolbar button.
Options are:
- QToolButton::InstantPopup Clicking anywhere on the toolbar button opens the popup menu.
- QToolButton::DelayedPopup Clicking anywhere on the toolbar button triggers the default action. Clicking and holding the toolbar button opens the popup menu instead.
- QToolButton::MenuButtonPopup (Default) The toolbar button is split in a main button (triggers default action) and an arrow button (opens the popup menu).
- See also
- QToolButton
- Since
- 5.78
Definition at line 73 of file ktoolbarpopupaction.cpp.
The documentation for this class was generated from the following files:
Documentation copyright © 1996-2023 The KDE developers.
Generated on Sun Jun 4 2023 04:00:53 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.