package ocgtk

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Module Wrappers.Recent_info

type t = [ `recent_info ] Gobject.obj

`GtkRecentInfo` contains the metadata associated with an item in the recently used files list.

val ref : t -> t

Increases the reference count of @recent_info by one.

val match_ : t -> t -> bool

Checks whether two `GtkRecentInfo` point to the same resource.

val last_application : t -> string

Gets the name of the last application that have registered the recently used resource represented by @info.

val is_local : t -> bool

Checks whether the resource is local or not by looking at the scheme of its URI.

val has_group : t -> string -> bool

Checks whether @group_name appears inside the groups registered for the recently used item @info.

val has_application : t -> string -> bool

Checks whether an application registered this resource using @app_name.

val get_uri_display : t -> string option

Gets a displayable version of the resource’s URI.

If the resource is local, it returns a local path; if the resource is not local, it returns the UTF-8 encoded content of method@Gtk.RecentInfo.get_uri.

val get_uri : t -> string

Gets the URI of the resource.

val get_short_name : t -> string

Computes a valid UTF-8 string that can be used as the name of the item in a menu or list.

For example, calling this function on an item that refers to “file:///foo/bar.txt” will yield “bar.txt”.

val get_private_hint : t -> bool

Gets the value of the “private” flag.

Resources in the recently used list that have this flag set to %TRUE should only be displayed by the applications that have registered them.

val get_mime_type : t -> string

Gets the MIME type of the resource.

val get_groups : t -> string array * Gsize.t

Returns all groups registered for the recently used item @info.

The array of returned group names will be %NULL terminated, so length might optionally be %NULL.

val get_gicon : t -> Ocgtk_gio.Gio.Wrappers.Icon.t option

Retrieves the icon associated to the resource MIME type.

val get_display_name : t -> string

Gets the name of the resource.

If none has been defined, the basename of the resource is obtained.

val get_description : t -> string

Gets the (short) description of the resource.

val get_applications : t -> string array * Gsize.t

Retrieves the list of applications that have registered this resource.

val get_age : t -> int

Gets the number of days elapsed since the last update of the resource pointed by @info.

val exists : t -> bool

Checks whether the resource pointed by @info still exists. At the moment this check is done only on resources pointing to local files.

val create_app_info : t -> string option -> (Ocgtk_gio.Gio.Wrappers.App_info.t option, GError.t) result

Creates a `GAppInfo` for the specified `GtkRecentInfo`

In case of error, @error will be set either with a %GTK_RECENT_MANAGER_ERROR or a %G_IO_ERROR

val get_type : unit -> Gobject.Type.t