A QPushButton which is associated with an action.
More...
#include <ActionButton.h>
|
| ActionButton (QWidget *parent=nullptr) |
| Standard widget constructor.
|
|
bool | isRequiredProperty (const QString &name) override |
| Overloaded from base class.
|
|
void | setAction (QAction *action) |
| Set the action owner of this button, that is the action associated to the button. The button is configured immediately depending on the action status and the button and the action are connected together so that when the action is changed the button is updated and when the button has been clicked the 'action' is triggered.
|
|
QAction * | getAction () const |
| Gets the current associated action. When the action is set by name this value is effected too.
|
|
void | setActionByName (const QString &name) |
| Sets an 'action' by finding it in the parent child list by name. When found the getAction()
|
|
QString | getActionByName () const |
| Property handler function to retrieve the actions name.
|
|
void | updateButtonStatusFromAction () |
| Update the button status depending on a change on the action status. This slot is invoked each time the action "changed" signal is emitted.
|
|
virtual void | addPropertyPages (PropertySheetDialog *sheet) |
| Adds the pages specific for this object.
|
|
virtual bool | getSaveChildren () const |
| Gets if the children needs saving by the FormBuilder class.
|
|
|
static bool | inDesigner () |
| Gets the designer status.
|
|
static QObject * | getExtensionParent (QObject *obj, bool first=true) |
| Return if the passed object has this type as parent. It starts by testing the passed object itself.
|
|
| ObjectExtension (QObject *object) |
| Protected constructor only. Inlined so no external libs are need for designer.
|
|
virtual | ~ObjectExtension ()=default |
| Virtual destructor.
|
|
A QPushButton which is associated with an action.
◆ ActionButton()
sf::ActionButton::ActionButton |
( |
QWidget * |
parent = nullptr | ) |
|
|
explicit |
Standard widget constructor.
◆ getAction()
QAction * sf::ActionButton::getAction |
( |
| ) |
const |
Gets the current associated action. When the action is set by name this value is effected too.
- Returns
- Null when not set.
◆ getActionByName()
QString sf::ActionButton::getActionByName |
( |
| ) |
const |
Property handler function to retrieve the actions name.
- Returns
- Name of the action.
◆ isRequiredProperty()
bool sf::ActionButton::isRequiredProperty |
( |
const QString & |
name | ) |
|
|
overridevirtual |
◆ setAction()
void sf::ActionButton::setAction |
( |
QAction * |
action | ) |
|
Set the action owner of this button, that is the action associated to the button. The button is configured immediately depending on the action status and the button and the action are connected together so that when the action is changed the button is updated and when the button has been clicked the 'action' is triggered.
- Parameters
-
action | The action to associate to this button. |
◆ setActionByName()
void sf::ActionButton::setActionByName |
( |
const QString & |
name | ) |
|
Sets an 'action' by finding it in the parent child list by name. When found the getAction()
- Parameters
-
name | Name of the action to look for. |
◆ updateButtonStatusFromAction()
void sf::ActionButton::updateButtonStatusFromAction |
( |
| ) |
|
Update the button status depending on a change on the action status. This slot is invoked each time the action "changed" signal is emitted.
◆ action
QString sf::ActionButton::action |
|
readwrite |
The documentation for this class was generated from the following file: