Unity-6.0 Python API Documentation

Class: Unity.ActivationResponse

Subclass of: GObject.InitiallyUnowned

Properties

string"goto-uri"construct-only

Unity.HandledType"handled"construct-only

Constructors

 new(handled, goto_uri)

 with_preview(preview)

Class: Unity.AnnotatedIcon

Subclass of: GObject.Object

Properties

Unity.CategoryType"category"read/write

Unity.IconSizeHint"size-hint"read/write

string"ribbon"read/write

Gio.Icon"icon"read/write

Constructors

 new(base_icon)

Methods

stringto_string()

Class: Unity.AppInfoManager

Subclass of: GObject.Object

Signals

void"changed"(self, app_info_manager, id, new_appinfo)

Methods

voidclear()

Array<utf8>, intget_categories(id)

Unity.AppInfoManagerget_default()(static method)

Unity.AppInfoManagerget_instance()(static method)

Array<utf8>, intget_keywords(id)

stringget_path(id)

Gio.AppInfolookup(id)

voidlookup_async(id, _callback_, _callback__target)

Gio.AppInfolookup_finish(_res_)

Class: Unity.ApplicationPreview

Subclass of: Unity.Preview

Properties

string"last-update"read/write

string"copyright"read/write

Gio.Icon"app-icon"read/write

string"license"read/write

Constructors

Methods

voidset_rating(rating, num_ratings)

Class: Unity.AsyncPreview

Subclass of: Unity.Preview

Properties

Gio.Cancellable"cancellable"construct-only

Signals

void"preview_ready"(self, async_preview, preview)

Constructors

 new()

 with_cancellable(cancellable)

Methods

voidpreview_ready(preview)

Class: Unity.Category

Subclass of: GObject.Object

Properties

string"name"construct-only

Gio.Icon"icon-hint"construct-only

Unity.CategoryRenderer"default-renderer"construct-only

Constructors

Class: Unity.CheckOptionFilter

Subclass of: Unity.OptionsFilter

Constructors

Class: Unity.CheckOptionFilterCompact

Subclass of: Unity.OptionsFilter

Constructors

Abstract Class: Unity.Filter

Known subclasses: Unity.RatingsFilter, Unity.OptionsFilter

Subclass of: GObject.Object

Properties

bool"filtering"construct-only

bool"collapsed"construct-only

bool"visible"construct-only

Unity.FilterRenderer"renderer"construct-only

Gio.Icon"icon-hint"construct-only

string"display-name"construct-only

string"id"construct-only

Signals

void"changed"(self, filter)

Class: Unity.FilterOption

Subclass of: GObject.Object

Properties

bool"active"construct-only

string"display-name"construct-only

string"id"construct-only

Gio.Icon"icon-hint"construct-only

Constructors

Class: Unity.GenericPreview

Subclass of: Unity.Preview

Constructors

Class: Unity.InfoHint

Subclass of: GObject.InitiallyUnowned

Properties

string"display-name"construct-only

GLib.Variant"data"construct-only

string"id"construct-only

Gio.Icon"icon-hint"construct-only

Constructors

 with_variant(id, display_name, icon_hint, data)

Class: Unity.Inspector

Subclass of: GObject.Object

Properties

bool"unity-running"read-only

string"unity-bus-name"read-only

Methods

Unity.Inspectorget_default()(static method)

Class: Unity.LauncherEntry

Implements: Dee.Serializable

Subclass of: GObject.Object

Properties

int"count"read/write

bool"progress-visible"read/write

bool"count-visible"read/write

string"app-uri"construct-only

Dbusmenu.Menuitem"quicklist"read/write

bool"urgent"read/write

float"progress"read/write

Methods

Unity.LauncherEntryget_for_app_uri(app_uri)(static method)

Unity.LauncherEntryget_for_desktop_file(desktop_file)(static method)

Unity.LauncherEntryget_for_desktop_id(desktop_id)(static method)

Class: Unity.LauncherFavorites

Subclass of: GObject.Object

Signals

void"changed"(self, launcher_favorites)

Methods

Array<Gio.AppInfo>, intenumerate_app_infos()

Array<utf8>, intenumerate_ids()

Unity.LauncherFavoritesget_default()(static method)

boolhas_app_id(app_id)

boolhas_app_info(appinfo)

Gio.AppInfolookup(app_id)

Class: Unity.Lens

Subclass of: GObject.Object

Properties

Unity.MergeStrategy"global-merge-strategy"read/write

string"sources-display-name"construct-only

Unity.MergeStrategy"merge-strategy"read/write

bool"searching"read/write

string"search-hint"read/write

bool"visible"read/write

bool"search-in-global"read/write

bool"exported"read/write

GLib.List"filters"read/write

bool"active"read/write

string"dbus-path"construct-only

string"id"construct-only

GLib.List"categories"read/write

string"home-lens-default-name"read/write

Constructors

 new(dbus_path_, id_)

Methods

voidadd_local_scope(scope)

voidexport()

Class: Unity.LensSearch

Subclass of: GObject.InitiallyUnowned

Properties

GLib.HashTable"hints"construct-only

Dee.SerializableModel"results-model"construct-only

string"search-string"construct-only

Signals

void"finished"(self, lens_search)

Constructors

Methods

boolequals(other)

voidfinished()

voidset_reply_hint(key, variant)

Interface: Unity.MergeStrategy

Methods

Dee.ModelItermerge_result(target, row, row_length1)

Class: Unity.MoviePreview

Subclass of: Unity.Preview

Properties

string"year"read/write

Constructors

Methods

voidset_rating(rating, num_ratings)

Class: Unity.MultiRangeFilter

Subclass of: Unity.OptionsFilter

Constructors

Methods

Unity.FilterOptionget_first_active()

Unity.FilterOptionget_last_active()

Class: Unity.MusicPlayer

Subclass of: GObject.Object

Properties

bool"can-play"read/write

Unity.Playlist"current-playlist"read/write

Gio.AppInfo"app-info"construct-only

bool"can-go-next"read/write

string"title"read/write

bool"can-go-previous"read/write

bool"can-pause"read/write

bool"is-blacklisted"read/write

Dbusmenu.Menuitem"track-menu"read/write

string"desktop-file-name"construct-only

Unity.TrackMetadata"current-track"read/write

Unity.PlaybackState"playback-state"read/write

Dbusmenu.Menuitem"player-menu"read/write

Signals

void"activate_playlist"(self, music_player, playlist_id)

void"next"(self, music_player)

void"previous"(self, music_player)

void"raise"(self, music_player)

void"play_pause"(self, music_player)

Constructors

 new(desktop)

Methods

booladd_playlist(p)

voidedit_playlist_name(id, name)

voidexport()

Array<Unity.Playlist>, intget_playlists()

boolremove_playlist(p)

voidunexport()

Class: Unity.MusicPreview

Subclass of: Unity.Preview

Properties

string"current-track-uri"read/write

Unity.MusicPreviewTrackState"current-track-state"read/write

float"current-progress"read/write

Signals

void"play"(self, music_preview, uri)

void"pause"(self, music_preview, uri)

Constructors

 new(title, subtitle, image)

Methods

voidadd_track(track)

Class: Unity.OptionsFilter

Known subclasses: Unity.CheckOptionFilterCompact, Unity.MultiRangeFilter, Unity.CheckOptionFilter, Unity.RadioOptionFilter

Subclass of: Unity.Filter

Properties

Unity.OptionsFilterSortType"sort-type"read/write

Constructors

 new()

Methods

Unity.FilterOptionadd_option(id, display_name, icon_hint)

Unity.FilterOptionget_option(id)

boolremove_option(id)

Class: Unity.Playlist

Subclass of: GObject.Object

Properties

string"name"read/write

GLib.DateTime"last-play-date"read/write

GLib.DateTime"creation-date"read/write

GLib.DateTime"modification-date"read/write

string"id"construct-only

Gio.Icon"icon"read/write

Constructors

 new(id)

Class: Unity.PreferencesManager

Subclass of: GObject.Object

Properties

Unity.PreferencesManagerRemoteContent"remote-content-search"read/write

Methods

Unity.PreferencesManagerget_default()(static method)

Abstract Class: Unity.Preview

Implements: Dee.Serializable

Known subclasses: Unity.MoviePreview, Unity.SocialPreview, Unity.ApplicationPreview, Unity.MusicPreview, Unity.AsyncPreview, Unity.GenericPreview

Subclass of: GObject.Object

Properties

Gio.Icon"image"read/write

string"subtitle"read/write

string"description-markup"read/write

string"image-source-uri"read/write

string"title"read/write

Signals

void"closed"(self, preview)

Methods

voidadd_action(action)

voidadd_info(info_hint)

Class: Unity.PreviewAction

Implements: Dee.Serializable

Subclass of: GObject.Object

Properties

Gio.Icon"icon-hint"construct-only

Unity.LayoutHint"layout-hint"construct-only

string"display-name"construct-only

string"extra-text"read/write

string"id"construct-only

GLib.HashTable"hints"read-only

Signals

Unity.ActivationResponse"activated"(self, preview_action, uri)

Constructors

 with_layout_hint(id, display_name, icon_hint, layout)

Class: Unity.RadioOptionFilter

Subclass of: Unity.OptionsFilter

Constructors

Methods

Unity.FilterOptionget_active_option()

Class: Unity.RatingsFilter

Subclass of: Unity.Filter

Properties

float"rating"construct-only

Constructors

Class: Unity.Scope

Subclass of: GObject.Object

Properties

bool"provides-personal-content"read/write

Unity.OptionsFilter"sources"read/write

bool"search-in-global"read/write

bool"exported"read/write

GLib.List"filters"read-only

Dee.SerializableModel"results-model"read-only

bool"active"read/write

Dee.SerializableModel"global-results-model"read-only

string"dbus-path"construct-only

Signals

void"search_changed"(self, scope, search, search_type, cancellable)

Unity.Preview"preview_uri"(self, scope, uri)

void"active_sources_changed"(self, scope, active_ids, active_ids_length1)

void"filters_changed"(self, scope)

string"generate_search_key"(self, scope, search)

Unity.ActivationResponse"activate_uri"(self, scope, uri)

Constructors

 new(dbus_path_)

Methods

voidexport()

Unity.Filterget_filter(id)

voidinvalidate_search(search_type)

voidqueue_search_changed(search_type)

Class: Unity.SocialPreview

Subclass of: Unity.Preview

Properties

string"content"read/write

Gio.Icon"avatar"read/write

string"sender"read/write

Constructors

Methods

voidadd_comment(comment)

Class: Unity.SocialPreviewComment

Subclass of: GObject.InitiallyUnowned

Properties

string"text"construct-only

string"time"construct-only

string"id"construct-only

string"name"construct-only

Constructors

 new(id, name, text, time)

Class: Unity.TrackMetadata

Subclass of: GObject.Object

Properties

string"album"read/write

Gio.Icon"art-icon"read/write

string"title"read/write

Gio.File"art-location"read/write

string"artist"read/write

string"uri"read/write

int"length"read/write

int"track-no"read/write

Constructors

 new()

Enum: Unity.OptionsFilterSortType

MANUAL0DISPLAY_NAME1ID2

Enum: Unity.FilterRenderer

CHECK_OPTIONS0RADIO_OPTIONS1MULTIRANGE2RATINGS3CHECK_OPTIONS_COMPACT4

Enum: Unity.SearchType

DEFAULT0GLOBAL1N_TYPES2

Enum: Unity.LayoutHint

NONE0LEFT1RIGHT2TOP3BOTTOM4

Enum: Unity.IconSizeHint

DEFAULT0SMALL1LARGE2

Enum: Unity.HandledType

NOT_HANDLED0SHOW_DASH1HIDE_DASH2GOTO_DASH_URI3SHOW_PREVIEW4

Enum: Unity.PlaybackState

PLAYING0PAUSED1

Enum: Unity.CategoryType

NONE0APPLICATION1BOOK2MUSIC3MOVIE4GAMES5ELECTRONICS6COMPUTERS7OFFICE8HOME9GARDEN10PETS11TOYS12CHILDREN13BABY14CLOTHES15SHOES16WATCHES17SPORTS18OUTDOORS19GROCERY20HEALTH21BEAUTY22DIY23TOOLS24CAR25N_CATEGORIES26

Enum: Unity.MusicPreviewTrackState

STOPPED0PLAYING1PAUSED2

Enum: Unity.PreferencesManagerRemoteContent

ALL0NONE1

Enum: Unity.CategoryRenderer

VERTICAL_TILE0HORIZONTAL_TILE1LIST_TILE2FLOW3