gtk.RadioAction — an action that can be grouped so that only one can be active (new in PyGTK 2.4)
class gtk.RadioAction(gtk.ToggleAction): |
|
gobject.GObject Signal Prototypes
gtk.ToggleAction Signal Prototypes
"changed" | def callback(radioaction, current, user_param1, ...) |
This object is available in PyGTK 2.4 and above.
A gtk.RadioAction is a subclass of gtk.ToggleAction and similar to gtk.RadioMenuItem. A number of radio actions can be linked together so that only one may be active at any one time.
|
name : | A unique name for the action |
label : | The label displayed in menu items and on buttons |
tooltip : | A tooltip for this action |
stock_id : | The stock icon to display in widgets representing this action |
value : | A unique integer value that get_current_value() should return if this action is selected. |
Returns : | a new gtk.RadioAction |
This constructor is available in PyGTK 2.4 and above.
Creates a new gtk.RadioAction object suing the properties specified by: name, label, tooltip, stock_id and value. To add the action to a gtk.ActionGroup and set the accelerator for the action, call the gtk.ActionGroup.add_action_with_accel().
|
group : | another gtk.RadioAction or None |
This method is available in PyGTK 2.4 and above.
The set_group() method sets the radio group for the radio action to the same group as the gtk.RadioAction specified by group i.e. the radio action joins the group.
In PyGTK 2.6.2 and above, if group is None the radio action is removed from its current group.
|
Returns : | a list containing the radio actions in the group or None |
This method is available in PyGTK 2.4 and above.
The get_group() method returns a list containing the group that the radio action belongs to or None if the radio action is not part of a group.
|
Returns : | The value of the currently active group member |
This method is available in PyGTK 2.4 and above.
The get_current_value() method returns the "value" property of the the currently active member of the group that the radio action belongs to.
|
radioaction : | the radioaction that received the signal |
current : | the currently active gtk.RadioAction in the group |
user_param1 : | the first user parameter (if any) specified with the connect() method |
... : | additional user parameters (if any) |
This signal is available in GTK+ 2.4 and above.
The "changed" signal is emitted on every member of a radio group when the active member is changed. The signal gets emitted after the "activate" signals for the previous and current active members.