Functions

  get_plugin_paths ()
  interface_create_header_button (header, button, icon_name, pack_type)
  interface_error (title, reason, parent)
  interface_error_blocking (title, reason, parent)
  interface_error_with_link (title, reason, uri, label, parent)
  interface_get_full_path (name)
  interface_load (name, fatal, parent, user_data)
  interface_load_pixbuf (name)
  interface_load_with_full_path (filename, fatal, parent, user_data)
  plugin_find_file (plugin_name, file)
  plugin_load_interface (plugin_name, name, fatal, parent, user_data)
  remote_command_quark ()
  remote_setting_quark ()

Details

Totem.get_plugin_paths()
Returns:a None-terminated array of paths to plugin directories
Return type:[str]

Return a None-terminated array of paths to directories which can contain Totem plugins. This respects the Gio.Settings disable_user_plugins setting.

New in version 2.90.0.

Totem.interface_create_header_button(header, button, icon_name, pack_type)
Parameters:
  • header (Gtk.Widget) – The header widget to put the button in
  • button (Gtk.Widget) – The button to use in the header
  • icon_name (str) – The icon name for the button image
  • pack_type (Gtk.PackType) – A Gtk.PackType to tell us where to include the button
Returns:

the button passed as input

Return type:

Gtk.Widget

Put the given icon_name into button, and pack button into header according to pack_type.

Totem.interface_error(title, reason, parent)
Parameters:
  • title (str) – the error title
  • reason (str) – the error reason (secondary text)
  • parent (Gtk.Window) – the error dialogue’s parent Gtk.Window

xlib.Display a modal error dialogue with title as its primary error text, and reason as its secondary text.

Totem.interface_error_blocking(title, reason, parent)
Parameters:
  • title (str) – the error title
  • reason (str) – the error reason (secondary text)
  • parent (Gtk.Window) – the error dialogue’s parent Gtk.Window

xlib.Display a modal error dialogue like Totem.interface_error() which blocks until the user has dismissed it.

Parameters:
  • title (str) – the error title
  • reason (str) – the error reason (secondary text)
  • uri (str) – the URI to open
  • label (str) – a label for the URI’s button, or None to use uri as the label
  • parent (Gtk.Window) – the error dialogue’s parent Gtk.Window

xlib.Display a modal error dialogue like Totem.interface_error(), but add a button which will open uri in a browser window.

Totem.interface_get_full_path(name)
Parameters:name (str) –
Return type:str
Totem.interface_load(name, fatal, parent, user_data)
Parameters:
Returns:

the loaded Gtk.Builder object, or None

Return type:

Gtk.Builder

Load a Gtk.Builder UI file with the given name and return the Gtk.Builder instance for it. If loading the file fails, an error dialogue is shown.

Totem.interface_load_pixbuf(name)
Parameters:name (str) – the image file name
Returns:the loaded pixbuf, or None
Return type:GdkPixbuf.Pixbuf

Load the image called name in the directory given by Totem.interface_get_full_path() into a GdkPixbuf.Pixbuf.

Totem.interface_load_with_full_path(filename, fatal, parent, user_data)
Parameters:
Returns:

the loaded Gtk.Builder object, or None

Return type:

Gtk.Builder

Load a Gtk.Builder UI file from the given path and return the Gtk.Builder instance for it. If loading the file fails, an error dialogue is shown.

Totem.plugin_find_file(plugin_name, file)
Parameters:
  • plugin_name (str) – the plugin name
  • file (str) – the file to find
Returns:

a newly-allocated absolute path for the file, or None

Return type:

str

Finds the specified file by looking in the plugin paths listed by Totem.get_plugin_paths() and then in the system Totem data directory.

This should be used by plugins to find plugin-specific resource files.

Totem.plugin_load_interface(plugin_name, name, fatal, parent, user_data)
Parameters:
  • plugin_name (str) – the plugin name
  • name (str) – interface filename
  • fatal (bool) – True if it’s a fatal error if the interface can’t be loaded
  • parent (Gtk.Window or None) – the interface’s parent Gtk.Window
  • user_data (object or None) – a pointer to be passed to each signal handler in the interface when they’re called
Returns:

the Gtk.Builder instance for the interface

Return type:

Gtk.Builder

Loads an interface file (Gtk.Builder UI file) for a plugin, given its filename and assuming it’s installed in the plugin’s data directory.

This should be used instead of attempting to load interfaces manually in plugins.

Totem.remote_command_quark()
Return type:int
Totem.remote_setting_quark()
Return type:int