| GIMP Widgets Library Reference Manual | ||||
|---|---|---|---|---|
| Top | Description | Object Hierarchy | Implemented Interfaces | Properties | ||||
GimpEnumStoreGimpEnumStore — A GimpIntStore subclass that keeps enum values. |
GimpEnumStore; GtkListStore * gimp_enum_store_new (GType enum_type); GtkListStore * gimp_enum_store_new_with_range (GType enum_type,gint minimum,gint maximum); GtkListStore * gimp_enum_store_new_with_values (GType enum_type,gint n_values,...); GtkListStore * gimp_enum_store_new_with_values_valist (GType enum_type,gint n_values,va_list args); void gimp_enum_store_set_stock_prefix (GimpEnumStore *store,const gchar *stock_prefix);
GimpEnumStore implements GtkTreeModel, GtkTreeDragSource, GtkTreeDragDest, GtkTreeSortable and GtkBuildable.
GtkListStore * gimp_enum_store_new (GType enum_type);
Creates a new GimpEnumStore, derived from GtkListStore and fills it with enum values. The enum needs to be registered to the type system and should have translatable value names.
|
the GType of an enum. |
Returns : |
a new GimpEnumStore. |
Since GIMP 2.4
GtkListStore * gimp_enum_store_new_with_range (GType enum_type,gint minimum,gint maximum);
Creates a new GimpEnumStore like gimp_enum_store_new() but allows
to limit the enum values to a certain range. Values smaller than
minimum or larger than maximum are not added to the store.
|
the GType of an enum. |
|
the minimum value to include |
|
the maximum value to include |
Returns : |
a new GimpEnumStore. |
Since GIMP 2.4
GtkListStore * gimp_enum_store_new_with_values (GType enum_type,gint n_values,...);
Creates a new GimpEnumStore like gimp_enum_store_new() but allows
to expliticely list the enum values that should be added to the
store.
|
the GType of an enum. |
|
the number of enum values to include |
|
a list of enum values (exactly n_values) |
Returns : |
a new GimpEnumStore. |
Since GIMP 2.4
GtkListStore * gimp_enum_store_new_with_values_valist (GType enum_type,gint n_values,va_list args);
See gimp_enum_store_new_with_values().
|
the GType of an enum. |
|
the number of enum values to include |
|
a va_list of enum values (exactly n_values) |
Returns : |
a new GimpEnumStore. |
Since GIMP 2.4
void gimp_enum_store_set_stock_prefix (GimpEnumStore *store,const gchar *stock_prefix);
Creates a stock ID for each enum value in the store by appending
the value's nick to the given stock_prefix, separated by a hyphen.
See also: gimp_enum_combo_box_set_stock_prefix().
|
a GimpEnumStore |
|
a prefix to create icon stock ID from enum values |
Since GIMP 2.4