An action which can be toggled between two states
Class GtkToggleAction( [name],[label],[tooltip],[stock_id] )
| name | A unique name for the action |
| label | The label displayed in menu items and on buttons |
| tooltip | A tooltip for the action |
| stock_id | The stock icon to display in widgets representing the action |
A GtkToggleAction corresponds roughly to a GtkCheckMenuItem. It has an "active" state specifying whether the action has been checked or not.
To add the action to a GtkActionGroup and set the accelerator for the action, call gtk_action_group_add_action_with_accel().
| Methods | |
| get_active | Returns the checked state of the toggle action. |
| get_draw_as_radio | Returns whether the action should have proxies like a radio action. |
| set_active | Sets the checked state on the toggle action. |
| set_draw_as_radio | Sets whether the action should have proxies like a radio action. |
| signal_toggled | Connect a VMSlot to the action toggled signal and return it |
| toggled | Emits the "toggled" signal on the toggle action. |
Returns the checked state of the toggle action.
GtkToggleAction.get_active()
| Return | the checked state of the toggle action |
Returns whether the action should have proxies like a radio action.
GtkToggleAction.get_draw_as_radio()
| Return | whether the action should have proxies like a radio action. |
Sets the checked state on the toggle action.
GtkToggleAction.set_active( is_active )
| is_active | (boolean) whether the action should be checked or not |
Sets whether the action should have proxies like a radio action.
GtkToggleAction.set_draw_as_radio( draw_as_radio )
| draw_as_radio | (boolean) whether the action should have proxies like a radio action |
Connect a VMSlot to the action toggled signal and return it
GtkToggleAction.signal_toggled()
Emits the "toggled" signal on the toggle action.
GtkToggleAction.toggled()