gtk.RecentActionAn action of which represents a list of recently used files (new in PyGTK 2.12)Synopsisgtk.RecentActiongtk.Actiongtk.RecentActionnamelabeltooltipstock_idget_show_numbersset_show_numbersshow_numbersFunctionsgtk.recent_action_new_for_managernamelabeltooltipstock_idmanagerAncestry+-- gobject.GObject
+-- gtk.Action
+-- gtk.RecentAction
gtk.RecentAction Propertiesgtk.Action Properties
"show-numbers"Read-WriteWhether the items should be displayed with a number.
Default value: False
Description
A gtk.RecentAction represents a list
of recently used files, which can be shown by widgets such as
gtk.RecentChooserDialog or
gtk.RecentChooserMenu.
To construct a submenu showing recently used files, use a
gtk.RecentAction
as the action for a <menuitem>. To construct a menu toolbutton showing
the recently used files in the popup menu, use a
gtk.RecentAction
as the action for a <toolitem> element.
Constructorgtk.RecentActiongtk.RecentActionnamelabeltooltipstock_idname :a unique name for the action label :the label displayed in menu items and on buttons, or None.tooltip :a tooltip for the action, or None.stock_id :the stock icon to display in widgets representing the action, or None.Returns :a new
gtk.RecentActionThis constructor is available in PyGTK 2.12 and above.
Creates a new
gtk.RecentAction
object. To add the action to a
gtk.ActionGroup
and set the accelerator for the action, call
gtk.ActionGroup.add_action_with_accel().
Methodsgtk.RecentAction.get_show_numbersget_show_numbersReturns :True if numbers should be shown.This method is available in PyGTK 2.12 and above.
The get_show_numbers() method returns the value set by
gtk.RecentAction.set_show_numbers().
gtk.RecentAction.set_show_numbersset_show_numbersshow_numbersshow_numbers :True if the shown items should be numbered.This method is available in PyGTK 2.12 and above.
The set_show_numbers() method sets whether a number
should be added to the items shown by the widgets representing action.
The numbers are shown to provide a unique character for a mnemonic to be
used inside the menu item's label. Only the first ten items get a number to avoid clashes.
Functionsgtk.recent_action_new_for_managerrecent_action_new_for_managernamelabeltooltipstock_idmanagername :a unique name for the action label :the label displayed in menu items and on buttons, or None.tooltip :a tooltip for the action, or None.stock_id :the stock icon to display in widgets representing the action, or None.manager :a gtk.RecentManager, or
None for using the default
gtk.RecentManagerThis function is available in PyGTK 2.12 and above.
The recent_action_new_for_manager() function creates a new
gtk.RecentAction object. To add the action to a
gtk.ActionGroup and set the accelerator for the action, call
gtk.ActionGroup.add_action_with_accel().