![]() | ![]() | ![]() | GPE Manual: libgpewidget Reference | ![]() |
---|
pixmapspixmaps — |
struct gpe_icon; gboolean gpe_load_icons (struct gpe_icon*); GdkPixbuf* gpe_find_icon (const gchar *name); GdkPixbuf* gpe_find_icon_scaled (const gchar *name, GtkIconSize size); GdkPixbuf* gpe_find_icon_scaled_free (const gchar *name, gint width, gint height); GdkPixbuf* gpe_try_find_icon (const gchar *name, gchar **error); gboolean gpe_find_icon_pixmap (const gchar *name, GdkPixmap **pixmap, GdkBitmap **bitmap); void gpe_set_theme (const gchar *theme_name); void gpe_set_window_icon (GtkWidget *window, gchar *icon);
struct gpe_icon { const gchar *shortname; const gchar *filename; GdkPixbuf *pixbuf; };
Struct defining a icon resource in GPE. It consists of three parts:
shortname: Short symbolic name to identify the icon.
filename: Image file with full path or file in theme location (PREFIX /share/gpe/pixmaps/<theme>).
pixbuf: GdkPixbuf with icon data.
GdkPixbuf* gpe_find_icon_scaled (const gchar *name, GtkIconSize size);
name : | |
size : | |
Returns : |
GdkPixbuf* gpe_find_icon_scaled_free (const gchar *name, gint width, gint height);
Find an icon by name and scale it to a new size defined by the user.
name : | |
width : | |
height : | |
Returns : |
GdkPixbuf* gpe_try_find_icon (const gchar *name, gchar **error);
name : | |
error : | |
Returns : |
gboolean gpe_find_icon_pixmap (const gchar *name, GdkPixmap **pixmap, GdkBitmap **bitmap);
name : | |
pixmap : | |
bitmap : | |
Returns : |
void gpe_set_theme (const gchar *theme_name);
Set the name of the theme used by GPE functions. This will cause GPE icon
functions to load icons from the given theme instead of the default location
(if the icon is present in the selected theme). The name of the theme points
GPE to the directory in $PREFIX/share/gpe/pixmaps where to search for the
themed icons. How the actual theme is set and changed needs to be handled
by the application.
Passing NULL to theme_name
resets the theme to the default/user theme.
theme_name : |
<< init | question >> |