diff options
author | Havoc Pennington <hp@redhat.com> | 2001-03-12 18:46:53 +0000 |
---|---|---|
committer | Havoc Pennington <hp@src.gnome.org> | 2001-03-12 18:46:53 +0000 |
commit | 10a173fedf26019270363b2a8e86286e9ca4b437 (patch) | |
tree | 99c3a1ca5ba65a84b21a06ba70994be04985938c /gtk/gtkiconfactory.h | |
parent | a647514c3393ef5d59b7b9ba11bcee1149519916 (diff) | |
download | gtk+-10a173fedf26019270363b2a8e86286e9ca4b437.tar.gz |
Switch to using an enum with registration for icon sizes, instead of
2001-03-12 Havoc Pennington <hp@redhat.com>
* gtk/gtkiconfactory.h, gtk/gtkiconfactory.c: Switch to using an
enum with registration for icon sizes, instead of strings.
* gtkimage.h, gtkimage.c, gtkstyle.h, gtkstyle.c, gtkwidget.h,
gtkwidget.c: Fix to reflect GtkIconSize
Diffstat (limited to 'gtk/gtkiconfactory.h')
-rw-r--r-- | gtk/gtkiconfactory.h | 31 |
1 files changed, 12 insertions, 19 deletions
diff --git a/gtk/gtkiconfactory.h b/gtk/gtkiconfactory.h index 1f26abb823..89c0f161c8 100644 --- a/gtk/gtkiconfactory.h +++ b/gtk/gtkiconfactory.h @@ -82,23 +82,16 @@ GtkIconSet* gtk_icon_factory_lookup_default (const gchar *stock_id); * size from the rendered pixbuf, not from here. */ -gboolean gtk_icon_size_lookup (const gchar *alias, - gint *width, - gint *height); -void gtk_icon_size_register (const gchar *alias, - gint width, - gint height); -void gtk_icon_size_register_alias (const gchar *alias, - const gchar *target); - - -/* Standard sizes */ - -#define GTK_ICON_SIZE_MENU "gtk-menu" -#define GTK_ICON_SIZE_SMALL_TOOLBAR "gtk-small-toolbar" -#define GTK_ICON_SIZE_LARGE_TOOLBAR "gtk-large-toolbar" -#define GTK_ICON_SIZE_BUTTON "gtk-button" -#define GTK_ICON_SIZE_DIALOG "gtk-dialog" +gboolean gtk_icon_size_lookup (GtkIconSize size, + gint *width, + gint *height); +GtkIconSize gtk_icon_size_register (const gchar *name, + gint width, + gint height); +void gtk_icon_size_register_alias (const gchar *alias, + GtkIconSize target); +GtkIconSize gtk_icon_size_from_name (const gchar *name); +G_CONST_RETURN gchar* gtk_icon_size_get_name (GtkIconSize size); /* Icon sets */ @@ -116,7 +109,7 @@ GdkPixbuf* gtk_icon_set_render_icon (GtkIconSet *icon_set, GtkStyle *style, GtkTextDirection direction, GtkStateType state, - const gchar *size, + GtkIconSize size, GtkWidget *widget, const char *detail); @@ -138,7 +131,7 @@ struct _GtkIconSource GtkTextDirection direction; GtkStateType state; - gchar *size; + GtkIconSize size; /* If TRUE, then the parameter is wildcarded, and the above * fields should be ignored. If FALSE, the parameter is |