W Wrapl, The Programming Language

Libraries:Gtk:Gio:GThemedIcon

Types

T

Inherits from:

T is an implementation of Gtk.Gio.GIcon.T that supports icon themes. T contains a list of all of the icons present in an icon theme, so that icons can be looked up quickly. T does not provide actual pixmaps for icons, just the icon names. Ideally something like Gtk.Gtk.IconTheme.ChooseIcon should be used to resolve the list of names so that fallback icons work nicely with themes that inherit other themes.



Constants

Nil : T

Functions

GetType() : Gtk.GObject.Type.T



New(iconname @ Std.String.T) : Gtk.Gio.GThemedIcon.T

Creates a new themed icon for iconname.

iconname a string containing an icon name.
Returns a new T. [transfer full]


NewFromNames(iconnames @ Std.Object.T, len @ Std.Integer.SmallT) : Gtk.Gio.GThemedIcon.T

Creates a new themed icon for iconnames.

iconnames an array of strings containing icon names. [array length=len]
len the length of the iconnames array, or -1 if iconnames is NULL-terminated
Returns a new T. [transfer full]


NewWithDefaultFallbacks(iconname @ Std.String.T) : Gtk.Gio.GThemedIcon.T

Creates a new themed icon for iconname, and all the names that can be created by shortening iconname at '-' characters.

In the following example, icon1 and icon2 are equivalent:

1
2
3
4
5
6
7
8
9
const char *names[] = { 
  "gnome-dev-cdrom-audio",
  "gnome-dev-cdrom",
  "gnome-dev",
  "gnome"
};

icon1 = g_themed_icon_new_from_names (names, 4);
icon2 = g_themed_icon_new_with_default_fallbacks ("gnome-dev-cdrom-audio");


Methods

:AppendName(self @ T, iconname @ Std.String.T) : Std.Object.T

Append a name to the list of icons from within icon.

Note

Note that doing so invalidates the hash computed by prior calls to Gtk.Gio.GIcon.Hash.



:GetNames(self @ T) : Agg.List.T

Gets the names of icons from within icon.

icon a T.
Returns a list of icon names. [transfer none]


:PrependName(self @ T, iconname @ Std.String.T) : Std.Object.T

Prepend a name to the list of icons from within icon.

Note

Note that doing so invalidates the hash computed by prior calls to Gtk.Gio.GIcon.Hash.