1
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
4
<meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
5
<title>GimpEnumWidgets</title>
6
<meta name="generator" content="DocBook XSL Stylesheets V1.72.0">
7
<link rel="start" href="index.html" title="GIMP Widgets Library Reference Manual">
8
<link rel="up" href="libgimpwidgets-utils.html" title="Part V. GIMP Widgets Utilities">
9
<link rel="prev" href="libgimpwidgets-GimpStock.html" title="GimpStock">
10
<link rel="next" href="libgimpwidgets-GimpPropWidgets.html" title="GimpPropWidgets">
11
<meta name="generator" content="GTK-Doc V1.8 (XML mode)">
12
<link rel="stylesheet" href="style.css" type="text/css">
13
<link rel="part" href="libgimpwidgets-widgets.html" title="Part I. GIMP Widgets">
14
<link rel="chapter" href="libgimpwidgets-hierarchy.html" title="Object Hierarchy">
15
<link rel="chapter" href="libgimpwidgets-gallery.html" title="Widget Gallery">
16
<link rel="chapter" href="libgimpwidgets-cell-renderers.html" title="Cell Renderers for GtkTreeView">
17
<link rel="part" href="libgimpwidgets-colordisplay.html" title="Part II. GIMP Display Filters">
18
<link rel="part" href="libgimpwidgets-colorselector.html" title="Part III. GIMP Color Selectors">
19
<link rel="part" href="libgimpwidgets-controller.html" title="Part IV. GIMP Controllers">
20
<link rel="part" href="libgimpwidgets-utils.html" title="Part V. GIMP Widgets Utilities">
21
<link rel="part" href="libgimpwidgets-deprecated.html" title="Part VI. Deprecated API">
22
<link rel="index" href="libgimpwidgets-index.html" title="Index">
23
<link rel="index" href="libgimpwidgets-index-new-in-2-2.html" title="Index of new symbols in GIMP 2.2">
24
<link rel="index" href="libgimpwidgets-index-new-in-2-4.html" title="Index of new symbols in GIMP 2.4">
25
<link rel="index" href="libgimpwidgets-index-deprecated.html" title="Index of deprecated symbols">
27
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
28
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
30
<td><a accesskey="p" href="libgimpwidgets-GimpStock.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
31
<td><a accesskey="u" href="libgimpwidgets-utils.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
32
<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
33
<th width="100%" align="center">GIMP Widgets Library Reference Manual</th>
34
<td><a accesskey="n" href="libgimpwidgets-GimpPropWidgets.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
36
<tr><td colspan="5" class="shortcuts"><nobr><a href="#id2573989" class="shortcut">Top</a>
38
<a href="#id2648831" class="shortcut">Description</a></nobr></td></tr>
40
<div class="refentry" lang="en">
41
<a name="libgimpwidgets-GimpEnumWidgets"></a><div class="titlepage"></div>
42
<div class="refnamediv"><table width="100%"><tr>
45
<a name="id2573989"></a><span class="refentrytitle">GimpEnumWidgets</span>
47
<p>GimpEnumWidgets</p>
49
<td valign="top" align="right"></td>
51
<div class="refsynopsisdiv">
53
<pre class="synopsis">
57
GtkWidget* <a href="libgimpwidgets-GimpEnumWidgets.html#gimp-enum-radio-box-new">gimp_enum_radio_box_new</a> (GType enum_type,
59
gpointer callback_data,
60
GtkWidget **first_button);
61
GtkWidget* <a href="libgimpwidgets-GimpEnumWidgets.html#gimp-enum-radio-box-new-with-range">gimp_enum_radio_box_new_with_range</a> (GType enum_type,
65
gpointer callback_data,
66
GtkWidget **first_button);
67
GtkWidget* <a href="libgimpwidgets-GimpEnumWidgets.html#gimp-enum-radio-frame-new">gimp_enum_radio_frame_new</a> (GType enum_type,
68
GtkWidget *label_widget,
70
gpointer callback_data,
71
GtkWidget **first_button);
72
GtkWidget* <a href="libgimpwidgets-GimpEnumWidgets.html#gimp-enum-radio-frame-new-with-range">gimp_enum_radio_frame_new_with_range</a>
76
GtkWidget *label_widget,
78
gpointer callback_data,
79
GtkWidget **first_button);
80
GtkWidget* <a href="libgimpwidgets-GimpEnumWidgets.html#gimp-enum-stock-box-new">gimp_enum_stock_box_new</a> (GType enum_type,
81
const gchar *stock_prefix,
82
GtkIconSize icon_size,
84
gpointer callback_data,
85
GtkWidget **first_button);
86
GtkWidget* <a href="libgimpwidgets-GimpEnumWidgets.html#gimp-enum-stock-box-new-with-range">gimp_enum_stock_box_new_with_range</a> (GType enum_type,
89
const gchar *stock_prefix,
90
GtkIconSize icon_size,
92
gpointer callback_data,
93
GtkWidget **first_button);
94
void <a href="libgimpwidgets-GimpEnumWidgets.html#gimp-enum-stock-box-set-child-padding">gimp_enum_stock_box_set_child_padding</a>
95
(GtkWidget *stock_box,
100
<div class="refsect1" lang="en">
101
<a name="id2648831"></a><h2>Description</h2>
106
<div class="refsect1" lang="en">
107
<a name="id2648846"></a><h2>Details</h2>
108
<div class="refsect2" lang="en">
109
<a name="id2648857"></a><h3>
110
<a name="gimp-enum-radio-box-new"></a>gimp_enum_radio_box_new ()</h3>
111
<a class="indexterm" name="id2648871"></a><pre class="programlisting">GtkWidget* gimp_enum_radio_box_new (GType enum_type,
113
gpointer callback_data,
114
GtkWidget **first_button);</pre>
116
Creates a new group of <span class="type">GtkRadioButtons</span> representing the enum
117
values. A group of radiobuttons is a good way to represent enums
118
with up to three or four values. Often it is better to use a
119
<a href="GimpEnumComboBox.html" title="GimpEnumComboBox"><span class="type">GimpEnumComboBox</span></a> instead.</p>
123
<div class="variablelist"><table border="0">
124
<col align="left" valign="top">
127
<td><span class="term"><em class="parameter"><code>enum_type</code></em> :</span></td>
128
<td> the <span class="type">GType</span> of an enum.
132
<td><span class="term"><em class="parameter"><code>callback</code></em> :</span></td>
133
<td> a callback to connect to the "toggled" signal of each
134
<span class="type">GtkRadioButton</span> that is created.
138
<td><span class="term"><em class="parameter"><code>callback_data</code></em> :</span></td>
139
<td> data to pass to the <em class="parameter"><code>callback</code></em>.
143
<td><span class="term"><em class="parameter"><code>first_button</code></em> :</span></td>
144
<td> returns the first button in the created group.
148
<td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td>
149
<td> a new <span class="type">GtkVBox</span> holding a group of <span class="type">GtkRadioButtons</span>.
155
<p class="since">Since GIMP 2.4
159
<div class="refsect2" lang="en">
160
<a name="id2649055"></a><h3>
161
<a name="gimp-enum-radio-box-new-with-range"></a>gimp_enum_radio_box_new_with_range ()</h3>
162
<a class="indexterm" name="id2659462"></a><pre class="programlisting">GtkWidget* gimp_enum_radio_box_new_with_range (GType enum_type,
166
gpointer callback_data,
167
GtkWidget **first_button);</pre>
169
Just like <a href="libgimpwidgets-GimpEnumWidgets.html#gimp-enum-radio-box-new"><code class="function">gimp_enum_radio_box_new()</code></a>, this function creates a group
170
of radio buttons, but it allows to limit the range of available
175
<div class="variablelist"><table border="0">
176
<col align="left" valign="top">
179
<td><span class="term"><em class="parameter"><code>enum_type</code></em> :</span></td>
180
<td> the <span class="type">GType</span> of an enum.
184
<td><span class="term"><em class="parameter"><code>minimum</code></em> :</span></td>
189
<td><span class="term"><em class="parameter"><code>maximum</code></em> :</span></td>
194
<td><span class="term"><em class="parameter"><code>callback</code></em> :</span></td>
195
<td> a callback to connect to the "toggled" signal of each
196
<span class="type">GtkRadioButton</span> that is created.
200
<td><span class="term"><em class="parameter"><code>callback_data</code></em> :</span></td>
201
<td> data to pass to the <em class="parameter"><code>callback</code></em>.
205
<td><span class="term"><em class="parameter"><code>first_button</code></em> :</span></td>
206
<td> returns the first button in the created group.
210
<td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td>
211
<td> a new <span class="type">GtkVBox</span> holding a group of <span class="type">GtkRadioButtons</span>.
217
<p class="since">Since GIMP 2.4
221
<div class="refsect2" lang="en">
222
<a name="id2659683"></a><h3>
223
<a name="gimp-enum-radio-frame-new"></a>gimp_enum_radio_frame_new ()</h3>
224
<a class="indexterm" name="id2659696"></a><pre class="programlisting">GtkWidget* gimp_enum_radio_frame_new (GType enum_type,
225
GtkWidget *label_widget,
227
gpointer callback_data,
228
GtkWidget **first_button);</pre>
230
Calls <a href="libgimpwidgets-GimpEnumWidgets.html#gimp-enum-radio-box-new"><code class="function">gimp_enum_radio_box_new()</code></a> and puts the resulting vbox into a
231
<span class="type">GtkFrame</span>.</p>
235
<div class="variablelist"><table border="0">
236
<col align="left" valign="top">
239
<td><span class="term"><em class="parameter"><code>enum_type</code></em> :</span></td>
240
<td> the <span class="type">GType</span> of an enum.
244
<td><span class="term"><em class="parameter"><code>label_widget</code></em> :</span></td>
245
<td> a widget to use as label for the frame that will
250
<td><span class="term"><em class="parameter"><code>callback</code></em> :</span></td>
251
<td> a callback to connect to the "toggled" signal of each
252
<span class="type">GtkRadioButton</span> that is created.
256
<td><span class="term"><em class="parameter"><code>callback_data</code></em> :</span></td>
257
<td> data to pass to the <em class="parameter"><code>callback</code></em>.
261
<td><span class="term"><em class="parameter"><code>first_button</code></em> :</span></td>
262
<td> returns the first button in the created group.
266
<td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td>
267
<td> a new <span class="type">GtkFrame</span> holding a group of <span class="type">GtkRadioButtons</span>.
273
<p class="since">Since GIMP 2.4
277
<div class="refsect2" lang="en">
278
<a name="id2647630"></a><h3>
279
<a name="gimp-enum-radio-frame-new-with-range"></a>gimp_enum_radio_frame_new_with_range ()</h3>
280
<a class="indexterm" name="id2647646"></a><pre class="programlisting">GtkWidget* gimp_enum_radio_frame_new_with_range
284
GtkWidget *label_widget,
286
gpointer callback_data,
287
GtkWidget **first_button);</pre>
289
Calls <a href="libgimpwidgets-GimpEnumWidgets.html#gimp-enum-radio-box-new-with-range"><code class="function">gimp_enum_radio_box_new_with_range()</code></a> and puts the resulting
290
vbox into a <span class="type">GtkFrame</span>.</p>
294
<div class="variablelist"><table border="0">
295
<col align="left" valign="top">
298
<td><span class="term"><em class="parameter"><code>enum_type</code></em> :</span></td>
299
<td> the <span class="type">GType</span> of an enum.
303
<td><span class="term"><em class="parameter"><code>minimum</code></em> :</span></td>
308
<td><span class="term"><em class="parameter"><code>maximum</code></em> :</span></td>
313
<td><span class="term"><em class="parameter"><code>label_widget</code></em> :</span></td>
314
<td> a widget to put into the frame that will hold the radio box.
318
<td><span class="term"><em class="parameter"><code>callback</code></em> :</span></td>
319
<td> a callback to connect to the "toggled" signal of each
320
<span class="type">GtkRadioButton</span> that is created.
324
<td><span class="term"><em class="parameter"><code>callback_data</code></em> :</span></td>
325
<td> data to pass to the <em class="parameter"><code>callback</code></em>.
329
<td><span class="term"><em class="parameter"><code>first_button</code></em> :</span></td>
330
<td> returns the first button in the created group.
334
<td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td>
335
<td> a new <span class="type">GtkFrame</span> holding a group of <span class="type">GtkRadioButtons</span>.
341
<p class="since">Since GIMP 2.4
345
<div class="refsect2" lang="en">
346
<a name="id2647898"></a><h3>
347
<a name="gimp-enum-stock-box-new"></a>gimp_enum_stock_box_new ()</h3>
348
<a class="indexterm" name="id2647911"></a><pre class="programlisting">GtkWidget* gimp_enum_stock_box_new (GType enum_type,
349
const gchar *stock_prefix,
350
GtkIconSize icon_size,
352
gpointer callback_data,
353
GtkWidget **first_button);</pre>
355
Creates a horizontal box of radio buttons with stock icons. The
356
stock_id for each icon is created by appending the enum_value's
357
nick to the given <em class="parameter"><code>stock_prefix</code></em>.</p>
361
<div class="variablelist"><table border="0">
362
<col align="left" valign="top">
365
<td><span class="term"><em class="parameter"><code>enum_type</code></em> :</span></td>
366
<td> the <span class="type">GType</span> of an enum.
370
<td><span class="term"><em class="parameter"><code>stock_prefix</code></em> :</span></td>
371
<td> the prefix of the group of stock ids to use.
375
<td><span class="term"><em class="parameter"><code>icon_size</code></em> :</span></td>
380
<td><span class="term"><em class="parameter"><code>callback</code></em> :</span></td>
381
<td> a callback to connect to the "toggled" signal of each
382
<span class="type">GtkRadioButton</span> that is created.
386
<td><span class="term"><em class="parameter"><code>callback_data</code></em> :</span></td>
387
<td> data to pass to the <em class="parameter"><code>callback</code></em>.
391
<td><span class="term"><em class="parameter"><code>first_button</code></em> :</span></td>
392
<td> returns the first button in the created group.
396
<td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td>
397
<td> a new <span class="type">GtkHbox</span> holding a group of <span class="type">GtkRadioButtons</span>.
403
<p class="since">Since GIMP 2.4
407
<div class="refsect2" lang="en">
408
<a name="id2653353"></a><h3>
409
<a name="gimp-enum-stock-box-new-with-range"></a>gimp_enum_stock_box_new_with_range ()</h3>
410
<a class="indexterm" name="id2653367"></a><pre class="programlisting">GtkWidget* gimp_enum_stock_box_new_with_range (GType enum_type,
413
const gchar *stock_prefix,
414
GtkIconSize icon_size,
416
gpointer callback_data,
417
GtkWidget **first_button);</pre>
419
Just like <a href="libgimpwidgets-GimpEnumWidgets.html#gimp-enum-stock-box-new"><code class="function">gimp_enum_stock_box_new()</code></a>, this function creates a group
420
of radio buttons, but it allows to limit the range of available
425
<div class="variablelist"><table border="0">
426
<col align="left" valign="top">
429
<td><span class="term"><em class="parameter"><code>enum_type</code></em> :</span></td>
430
<td> the <span class="type">GType</span> of an enum.
434
<td><span class="term"><em class="parameter"><code>minimum</code></em> :</span></td>
439
<td><span class="term"><em class="parameter"><code>maximum</code></em> :</span></td>
444
<td><span class="term"><em class="parameter"><code>stock_prefix</code></em> :</span></td>
445
<td> the prefix of the group of stock ids to use.
449
<td><span class="term"><em class="parameter"><code>icon_size</code></em> :</span></td>
454
<td><span class="term"><em class="parameter"><code>callback</code></em> :</span></td>
455
<td> a callback to connect to the "toggled" signal of each
456
<span class="type">GtkRadioButton</span> that is created.
460
<td><span class="term"><em class="parameter"><code>callback_data</code></em> :</span></td>
461
<td> data to pass to the <em class="parameter"><code>callback</code></em>.
465
<td><span class="term"><em class="parameter"><code>first_button</code></em> :</span></td>
466
<td> returns the first button in the created group.
470
<td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td>
471
<td> a new <span class="type">GtkHbox</span> holding a group of <span class="type">GtkRadioButtons</span>.
477
<p class="since">Since GIMP 2.4
481
<div class="refsect2" lang="en">
482
<a name="id2653632"></a><h3>
483
<a name="gimp-enum-stock-box-set-child-padding"></a>gimp_enum_stock_box_set_child_padding ()</h3>
484
<a class="indexterm" name="id2653648"></a><pre class="programlisting">void gimp_enum_stock_box_set_child_padding
485
(GtkWidget *stock_box,
489
Sets the padding of all buttons in a box created by
490
<a href="libgimpwidgets-GimpEnumWidgets.html#gimp-enum-stock-box-new"><code class="function">gimp_enum_stock_box_new()</code></a>.</p>
494
<div class="variablelist"><table border="0">
495
<col align="left" valign="top">
498
<td><span class="term"><em class="parameter"><code>stock_box</code></em> :</span></td>
499
<td> a stock box widget
503
<td><span class="term"><em class="parameter"><code>xpad</code></em> :</span></td>
504
<td> horizontal padding
508
<td><span class="term"><em class="parameter"><code>ypad</code></em> :</span></td>
509
<td> vertical padding
514
<p class="since">Since GIMP 2.4