Gtk.RecentChooserMenu¶
- Subclasses:
None
Methods¶
- Inherited:
Gtk.Menu (31), Gtk.MenuShell (14), Gtk.Container (35), Gtk.Widget (278), GObject.Object (37), Gtk.Buildable (10), Gtk.Activatable (6), Gtk.RecentChooser (31)
- Structs:
Gtk.ContainerClass (5), Gtk.WidgetClass (12), GObject.ObjectClass (5)
class |
|
class |
|
|
Virtual Methods¶
Properties¶
- Inherited:
Gtk.Menu (12), Gtk.MenuShell (1), Gtk.Container (3), Gtk.Widget (39), Gtk.Activatable (2), Gtk.RecentChooser (10)
Name |
Type |
Flags |
Short Description |
|---|---|---|---|
r/w/en |
Whether the items should be displayed with a number |
Child Properties¶
- Inherited:
Style Properties¶
- Inherited:
Signals¶
Fields¶
- Inherited:
Gtk.Menu (2), Gtk.MenuShell (8), Gtk.Container (4), Gtk.Widget (69), GObject.Object (1), Gtk.RecentChooser (2)
Name |
Type |
Access |
Description |
|---|---|---|---|
parent_instance |
r |
Class Details¶
- class Gtk.RecentChooserMenu(**kwargs)¶
- Bases:
- Abstract:
No
- Structure:
Gtk.RecentChooserMenuis a widget suitable for displaying recently used files inside a menu. It can be used to set a sub-menu of aGtk.MenuItemusingGtk.MenuItem.set_submenu(), or as the menu of aGtk.MenuToolButton.Note that
Gtk.RecentChooserMenudoes not have any methods of its own. Instead, you should use the functions that work on aGtk.RecentChooser.Note also that
Gtk.RecentChooserMenudoes not support multiple filters, as it has no way to let the user choose between them as theGtk.RecentChooserWidgetandGtk.RecentChooserDialogwidgets do. Thus usingGtk.RecentChooser.add_filter() on aGtk.RecentChooserMenuwidget will yield the same effects as usingGtk.RecentChooser.set_filter(), replacing any currently set filter with the supplied filter;Gtk.RecentChooser.remove_filter() will remove any currently setGtk.RecentFilterobject and will unset the current filter;Gtk.RecentChooser.list_filters() will return a list containing a singleGtk.RecentFilterobject.Recently used files are supported since GTK+ 2.10.
- classmethod new()[source]¶
- Returns:
a new
Gtk.RecentChooserMenu- Return type:
Creates a new
Gtk.RecentChooserMenuwidget.This kind of widget shows the list of recently used resources as a menu, each item as a menu item. Each item inside the menu might have an icon, representing its MIME type, and a number, for mnemonic access.
This widget implements the
Gtk.RecentChooserinterface.This widget creates its own
Gtk.RecentManagerobject. See theGtk.RecentChooserMenu.new_for_manager() function to know how to create aGtk.RecentChooserMenuwidget bound to anotherGtk.RecentManagerobject.New in version 2.10.
- classmethod new_for_manager(manager)[source]¶
- Parameters:
manager (
Gtk.RecentManager) – aGtk.RecentManager- Returns:
a new
Gtk.RecentChooserMenu, bound to manager.- Return type:
Creates a new
Gtk.RecentChooserMenuwidget using manager as the underlying recently used resources manager.This is useful if you have implemented your own recent manager, or if you have a customized instance of a
Gtk.RecentManagerobject or if you wish to share a commonGtk.RecentManagerobject among multipleGtk.RecentChooserwidgets.New in version 2.10.
- get_show_numbers()[source]¶
-
Returns the value set by
Gtk.RecentChooserMenu.set_show_numbers().New in version 2.10.
- set_show_numbers(show_numbers)[source]¶
- Parameters:
show_numbers (
bool) – whether to show numbers
Sets whether a number should be added to the items of self. The numbers are shown to provide a unique character for a mnemonic to be used inside ten menu item’s label. Only the first the items get a number to avoid clashes.
New in version 2.10.