Gtk.AppChooserDialog

g Atk.ImplementorIface Atk.ImplementorIface Gtk.Widget Gtk.Widget Atk.ImplementorIface->Gtk.Widget GObject.GInterface GObject.GInterface GObject.GInterface->Atk.ImplementorIface Gtk.AppChooser Gtk.AppChooser GObject.GInterface->Gtk.AppChooser Gtk.Buildable Gtk.Buildable GObject.GInterface->Gtk.Buildable GObject.InitiallyUnowned GObject.InitiallyUnowned GObject.InitiallyUnowned->Gtk.Widget GObject.Object GObject.Object GObject.Object->GObject.InitiallyUnowned Gtk.AppChooserDialog Gtk.AppChooserDialog Gtk.AppChooser->Gtk.AppChooserDialog Gtk.Bin Gtk.Bin Gtk.Window Gtk.Window Gtk.Bin->Gtk.Window Gtk.Buildable->Gtk.Widget Gtk.Container Gtk.Container Gtk.Container->Gtk.Bin Gtk.Dialog Gtk.Dialog Gtk.Dialog->Gtk.AppChooserDialog Gtk.Widget->Gtk.Container Gtk.Window->Gtk.Dialog

Example

../_images/AppChooserDialog.png
Subclasses:None

Properties

Inherited:Gtk.Dialog (1), Gtk.Window (33), Gtk.Container (3), Gtk.Widget (39), Gtk.AppChooser (1)
Name Type Flags Short Description
gfile Gio.File r/w/co The Gio.File used by the app chooser dialog
heading str r/w/en The text to show at the top of the dialog

Style Properties

Inherited:Gtk.Dialog (4), Gtk.Window (2), Gtk.Widget (17)

Fields

Inherited:Gtk.Dialog (2), Gtk.Window (5), Gtk.Container (4), Gtk.Widget (69), GObject.Object (1)
Name Type Access Description
parent Gtk.Dialog r  

Class Details

class Gtk.AppChooserDialog(*args, **kwargs)
Bases:Gtk.Dialog, Gtk.AppChooser
Abstract:No
Structure:Gtk.AppChooserDialogClass

Gtk.AppChooserDialog shows a Gtk.AppChooserWidget inside a Gtk.Dialog.

Note that Gtk.AppChooserDialog does not have any interesting methods of its own. Instead, you should get the embedded Gtk.AppChooserWidget using Gtk.AppChooserDialog.get_widget() and call its methods if the generic Gtk.AppChooser interface is not sufficient for your needs.

To set the heading that is shown above the Gtk.AppChooserWidget, use Gtk.AppChooserDialog.set_heading().

classmethod new(parent, flags, file)[source]
Parameters:
Returns:

a newly created Gtk.AppChooserDialog

Return type:

Gtk.Widget

Creates a new Gtk.AppChooserDialog for the provided Gio.File, to allow the user to select an application for it.

New in version 3.0.

classmethod new_for_content_type(parent, flags, content_type)[source]
Parameters:
Returns:

a newly created Gtk.AppChooserDialog

Return type:

Gtk.Widget

Creates a new Gtk.AppChooserDialog for the provided content type, to allow the user to select an application for it.

New in version 3.0.

get_heading()[source]
Returns:the text to display at the top of the dialog, or None, in which case a default text is displayed
Return type:str or None

Returns the text to display at the top of the dialog.

get_widget()[source]
Returns:the Gtk.AppChooserWidget of self
Return type:Gtk.Widget

Returns the Gtk.AppChooserWidget of this dialog.

New in version 3.0.

set_heading(heading)[source]
Parameters:heading (str) – a string containing Pango markup

Sets the text to display at the top of the dialog. If the heading is not set, the dialog displays a default text.

Property Details

Gtk.AppChooserDialog.props.gfile
Name:gfile
Type:Gio.File
Default Value:None
Flags:READABLE, WRITABLE, CONSTRUCT_ONLY

The Gio.File used by the Gtk.AppChooserDialog. The dialog’s Gtk.AppChooserWidget content type will be guessed from the file, if present.

Gtk.AppChooserDialog.props.heading
Name:heading
Type:str
Default Value:None
Flags:READABLE, WRITABLE, EXPLICIT_NOTIFY

The text to show at the top of the dialog. The string may contain Pango markup.