11.25Class GtkActivatable

An interface for activatable widgets

Class GtkActivatable

GtkActivatable is implemented by GtkTearoffMenuItem, GtkOptionMenu, GtkLinkButton, GtkRadioButton, GtkRadioToolButton, GtkToggleButton, GtkSeparatorMenuItem, GtkImageMenuItem, GtkCheckButton, GtkRadioMenuItem, GtkButton, GtkMenuToolButton, GtkMenuItem, GtkRecentChooserMenu, GtkToolItem, GtkSeparatorToolItem, GtkCheckMenuItem, GtkToolButton, GtkFontButton, GtkScaleButton, GtkToggleToolButton, GtkVolumeButton and GtkColorButton.

Activatable widgets can be connected to a GtkAction and reflects the state of its action. A GtkActivatable can also provide feedback through its action, as they are responsible for activating their related actions.

Methods
do_set_related_actionThis is a utility function for GtkActivatable implementors.
get_related_actionGets the related GtkAction for activatable.
get_use_action_appearanceGets whether this activatable should reset its layout and appearance when setting the related action or when the action changes appearance.
set_related_actionSets the related action on the activatable object.
set_use_action_appearanceSets whether this activatable should reset its layout and appearance when setting the related action or when the action changes appearance
sync_action_propertiesThis is called to update the activatable completely, this is called internally when the "related-action" property is set or unset and by the implementing class when "use-action-appearance" changes.

Methods

do_set_related_action

This is a utility function for GtkActivatable implementors.

GtkActivatable.do_set_related_action( action )
action the GtkAction to set

When implementing GtkActivatable you must call this when handling changes of the "related-action", and you must also use this to break references in GObject->dispose().

This function adds a reference to the currently set related action for you, it also makes sure the GtkActivatable->update() method is called when the related GtkAction properties change and registers to the action's proxy list.

Note: Be careful to call this before setting the local copy of the GtkAction property, since this function uses gtk_activatable_get_action() to retrieve the previous action.

get_related_action

Gets the related GtkAction for activatable.

GtkActivatable.get_related_action()
Returnthe related GtkAction if one is set.

get_use_action_appearance

Gets whether this activatable should reset its layout and appearance when setting the related action or when the action changes appearance.

GtkActivatable.get_use_action_appearance()
Returnwhether activatable uses its actions appearance.

set_related_action

Sets the related action on the activatable object.

GtkActivatable.set_related_action( action )
action the GtkAction to set

set_use_action_appearance

Sets whether this activatable should reset its layout and appearance when setting the related action or when the action changes appearance

GtkActivatable.set_use_action_appearance( use_appearance )
use_appearance whether to use the actions appearance

sync_action_properties

This is called to update the activatable completely, this is called internally when the "related-action" property is set or unset and by the implementing class when "use-action-appearance" changes.

GtkActivatable.sync_action_properties( action )
action the related GtkAction or NULL.
Made with http://www.falconpl.org