Gjsify LogoGjsify Logo

Index

Variables

DESKTOP_PLATFORM_VERSION: number
RR_CONNECTOR_TYPE_PANEL: string

Functions

  • desktop_thumbnail_is_valid(pixbuf: Pixbuf, uri: string, mtime: number): boolean
  • Returns whether the thumbnail has the correct uri and mtime embedded in the png options. This function is threadsafe and does no blocking I/O.

    Parameters

    • pixbuf: Pixbuf

      an loaded thumbnail #GdkPixbuf

    • uri: string

      a uri

    • mtime: number

      the mtime

    Returns boolean

  • get_all_locales(): string[]
  • get_country_from_code(code: string, translation: string): string
  • Gets the country name for code. If translation is provided the returned string is translated accordingly.

    Parameters

    • code: string

      an ISO 3166 code string

    • translation: string

      a locale string

    Returns string

  • get_country_from_locale(locale: string, translation: string): string
  • Gets the country description for locale. If translation is provided the returned string is translated accordingly.

    Parameters

    • locale: string

      a locale string

    • translation: string

      a locale string

    Returns string

  • get_input_source_from_locale(locale: string): [boolean, string, string]
  • Gets the default input source's type and identifier for a given locale.

    Parameters

    • locale: string

      a locale string

    Returns [boolean, string, string]

  • get_language_from_code(code: string, translation: string): string
  • Gets the language name for code. If translation is provided the returned string is translated accordingly.

    Parameters

    • code: string

      an ISO 639 code string

    • translation: string

      a locale string

    Returns string

  • get_language_from_locale(locale: string, translation: string): string
  • Gets the language description for locale. If translation is provided the returned string is translated accordingly.

    Parameters

    • locale: string

      a locale string

    • translation: string

      a locale string

    Returns string

  • get_platform_version(): number
  • Returns an integer with the major version of GNOME. Useful for dynamic languages like Javascript or Python (static languages like C should use %GNOME_DESKTOP_PLATFORM_VERSION). If this function doesn't exist, it can be presumed that the GNOME platform version is 42 or previous.

    Returns number

  • get_translated_modifier(modifier: string, translation: string): string
  • Gets a translation of the raw modifier string. If translation is provided the returned string is translated accordingly.

    Parameters

    • modifier: string

      the modifier part of a locale name

    • translation: string

      a locale string

    Returns string

  • language_has_translations(code: string): boolean
  • normalize_locale(locale: string): string
  • Gets the normalized locale string in the form [language[_country][.codeset][modifier]] for name.

    Parameters

    • locale: string

      a locale string

    Returns string

  • parse_locale(locale: string): [boolean, string, string | null, string | null, string | null]
  • If the current process is running inside a user systemd instance, then move the launched PID into a transient scope. The given name will be used to create a unit name. It should be the application ID or the executable in all other cases. If a desktop-id is passed then the .desktop suffix will be stripped.

    It is advisable to use this function every time where the started application can be considered reasonably independent of the launching application. Placing it in a scope creates proper separation between the programs rather than being considered a single entity by systemd.

    It is always safe to call this function. Note that a successful return code does not imply that a unit has been created. It solely means that no error condition was hit sending the request.

    If connection is %NULL then g_dbus_get() will be called internally.

    Note that most callers will not need to handle errors. As such, it is normal to pass a %NULL callback.

    Parameters

    • name: string

      Name for the application

    • pid: number

      The PID of the application

    • description: string

      A description to use for the unit, or %NULL

    • connection: DBusConnection

      An #GDBusConnection to the session bus, or %NULL

    • cancellable: Gio.Cancellable

      #GCancellable to use

    • callback: AsyncReadyCallback

      Callback to call when the operation is done

    Returns void

  • Finish an asynchronous operation to create a transient scope that was started with gnome_start_systemd_scope().

    Note that a successful return code does not imply that a unit has been created. It solely means that no error condition was hit sending the request.

    Parameters

    Returns boolean

Legend

  • Module
  • Object literal
  • Variable
  • Function
  • Function with type parameter
  • Index signature
  • Type alias
  • Type alias with type parameter
  • Enumeration
  • Enumeration member
  • Property
  • Method
  • Interface
  • Interface with type parameter
  • Constructor
  • Property
  • Method
  • Index signature
  • Class
  • Class with type parameter
  • Constructor
  • Property
  • Method
  • Accessor
  • Index signature
  • Inherited constructor
  • Inherited property
  • Inherited method
  • Inherited accessor
  • Protected property
  • Protected method
  • Protected accessor
  • Private property
  • Private method
  • Private accessor
  • Static property
  • Static method