Superclass: g-object
Subclasses: recent-action toggle-action
Actions represent operations that the user can be perform, along with some information how it should be presented in the interface. Each action provides methods to create icons, menu items and toolbar items representing itself.
As well as the callback that is called when the action gets activated, the following also gets associated with the action:
Each action can have one or more proxy menu item, toolbar button or other proxy widgets. Proxies mirror the state of the action (text label, tooltip, icon, visible, sensitive, etc), and should change when the action's state changes. When the proxy is activated, it should activate its action.
Slots:
action-accel-group
. Write-only.
string
. Accessor: action-accel-path
.
action-action-group
.
The action-group this action is associated with, or NIL
(for internal use).
GIcon
. Accessor: action-gicon
.
The GIcon
displayed in the action.
Note that the stock icon is preferred, if the action-stock-id property holds the id of an existing stock icon.
This is an appearance property and thus only applies if activatable-use-action-appearance is true.
boolean
. Accessor: action-hide-if-empty
.
When TRUE, empty menu proxies for this action are hidden.
Default value: TRUE
string
. Accessor: action-icon-name
.
The name of the icon from the icon theme.
Note that the stock icon is preferred, if the action-stock-id property holds the id of an existing stock icon, and the GIcon
is preferred if the action-gicon property is set.
This is an appearance property and thus only applies if activatable-use-action-appearance is TRUE.
Default value: NIL
boolean
. Accessor: action-is-important
.
Whether the action is considered important. When TRUE, toolitem proxies for this action show text in :both-horiz
mode.
Default value: FALSE
string
. Accessor: action-label
.
The label used for menu items and buttons that activate this action. If the label is NULL, GTK+ uses the stock label specified via the stock-id property.
This is an appearance property and thus only applies if activatable-use-action-appearance is TRUE.
Default value: NIL
string
. Accessor: action-name
.
A unique name for the action.
Default value: NIL
boolean
. Accessor: action-sensitive
.
Whether the action is enabled.
Default value: TRUE
string
. Accessor: action-short-label
.
A shorter label that may be used on toolbar buttons.
This is an appearance property and thus only applies if activatable-use-action-appearance is TRUE.
Default value: NIL
string
. Accessor: action-stock-id
.
The stock icon displayed in widgets representing this action.
This is an appearance property and thus only applies if activatable-use-action-appearance is TRUE.
Default value: NIL
string
. Accessor: action-tooltip
.
A tooltip for this action.
Default value: NIL
boolean
. Accessor: action-visible
.
Whether the action is visible.
Default value: TRUE
boolean
. Accessor: action-visible-horizontal
.
Whether the toolbar item is visible when the toolbar is in a horizontal orientation.
Default value: TRUE
boolean
. Accessor: action-visible-overflown
.
When TRUE, toolitem proxies for this action are represented in the toolbar overflow menu.
Default value: TRUE
boolean
. Accessor: action-visible-vertical
.
Whether the toolbar item is visible when the toolbar is in a vertical orientation.
Default value: TRUE
Signals:
The activate
signal is emitted when the action is activated.