1
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
4
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
6
<meta name="generator" content="DocBook XSL Stylesheets V1.77.1">
7
<link rel="home" href="index.html" title="GTK+ 2 Reference Manual">
8
<link rel="up" href="AbstractObjects.html" title="Abstract Base Classes">
9
<link rel="prev" href="GtkMenuShell.html" title="GtkMenuShell">
10
<link rel="next" href="GtkObject.html" title="GtkObject">
11
<meta name="generator" content="GTK-Doc V1.18 (XML mode)">
12
<link rel="stylesheet" href="style.css" type="text/css">
14
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
15
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
17
<td><a accesskey="p" href="GtkMenuShell.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
18
<td><a accesskey="u" href="AbstractObjects.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
19
<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
20
<th width="100%" align="center">GTK+ 2 Reference Manual</th>
21
<td><a accesskey="n" href="GtkObject.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
23
<tr><td colspan="5" class="shortcuts">
24
<a href="#GtkMisc.synopsis" class="shortcut">Top</a>
26
<a href="#GtkMisc.description" class="shortcut">Description</a>
28
<a href="#GtkMisc.object-hierarchy" class="shortcut">Object Hierarchy</a>
30
<a href="#GtkMisc.implemented-interfaces" class="shortcut">Implemented Interfaces</a>
32
<a href="#GtkMisc.properties" class="shortcut">Properties</a>
35
<div class="refentry">
36
<a name="GtkMisc"></a><div class="titlepage"></div>
37
<div class="refnamediv"><table width="100%"><tr>
39
<h2><span class="refentrytitle"><a name="GtkMisc.top_of_page"></a>GtkMisc</span></h2>
40
<p>GtkMisc — Base class for widgets with alignments and padding</p>
42
<td valign="top" align="right"></td>
44
<div class="refsynopsisdiv">
45
<a name="GtkMisc.synopsis"></a><h2>Synopsis</h2>
46
<pre class="synopsis">
47
#include <gtk/gtk.h>
49
struct <a class="link" href="GtkMisc.html#GtkMisc-struct" title="struct GtkMisc">GtkMisc</a>;
50
<span class="returnvalue">void</span> <a class="link" href="GtkMisc.html#gtk-misc-set-alignment" title="gtk_misc_set_alignment ()">gtk_misc_set_alignment</a> (<em class="parameter"><code><a class="link" href="GtkMisc.html" title="GtkMisc"><span class="type">GtkMisc</span></a> *misc</code></em>,
51
<em class="parameter"><code><span class="type">gfloat</span> xalign</code></em>,
52
<em class="parameter"><code><span class="type">gfloat</span> yalign</code></em>);
53
<span class="returnvalue">void</span> <a class="link" href="GtkMisc.html#gtk-misc-set-padding" title="gtk_misc_set_padding ()">gtk_misc_set_padding</a> (<em class="parameter"><code><a class="link" href="GtkMisc.html" title="GtkMisc"><span class="type">GtkMisc</span></a> *misc</code></em>,
54
<em class="parameter"><code><span class="type">gint</span> xpad</code></em>,
55
<em class="parameter"><code><span class="type">gint</span> ypad</code></em>);
56
<span class="returnvalue">void</span> <a class="link" href="GtkMisc.html#gtk-misc-get-alignment" title="gtk_misc_get_alignment ()">gtk_misc_get_alignment</a> (<em class="parameter"><code><a class="link" href="GtkMisc.html" title="GtkMisc"><span class="type">GtkMisc</span></a> *misc</code></em>,
57
<em class="parameter"><code><span class="type">gfloat</span> *xalign</code></em>,
58
<em class="parameter"><code><span class="type">gfloat</span> *yalign</code></em>);
59
<span class="returnvalue">void</span> <a class="link" href="GtkMisc.html#gtk-misc-get-padding" title="gtk_misc_get_padding ()">gtk_misc_get_padding</a> (<em class="parameter"><code><a class="link" href="GtkMisc.html" title="GtkMisc"><span class="type">GtkMisc</span></a> *misc</code></em>,
60
<em class="parameter"><code><span class="type">gint</span> *xpad</code></em>,
61
<em class="parameter"><code><span class="type">gint</span> *ypad</code></em>);
64
<div class="refsect1">
65
<a name="GtkMisc.object-hierarchy"></a><h2>Object Hierarchy</h2>
66
<pre class="synopsis">
68
+----GInitiallyUnowned
69
+----<a class="link" href="GtkObject.html" title="GtkObject">GtkObject</a>
70
+----<a class="link" href="GtkWidget.html" title="GtkWidget">GtkWidget</a>
72
+----<a class="link" href="GtkLabel.html" title="GtkLabel">GtkLabel</a>
73
+----<a class="link" href="GtkArrow.html" title="GtkArrow">GtkArrow</a>
74
+----<a class="link" href="GtkImage.html" title="GtkImage">GtkImage</a>
75
+----<a class="link" href="GtkPixmap.html" title="GtkPixmap">GtkPixmap</a>
78
<div class="refsect1">
79
<a name="GtkMisc.implemented-interfaces"></a><h2>Implemented Interfaces</h2>
82
AtkImplementorIface and <a class="link" href="GtkBuildable.html" title="GtkBuildable">GtkBuildable</a>.</p>
84
<div class="refsect1">
85
<a name="GtkMisc.properties"></a><h2>Properties</h2>
86
<pre class="synopsis">
87
"<a class="link" href="GtkMisc.html#GtkMisc--xalign" title='The "xalign" property'>xalign</a>" <span class="type">gfloat</span> : Read / Write
88
"<a class="link" href="GtkMisc.html#GtkMisc--xpad" title='The "xpad" property'>xpad</a>" <span class="type">gint</span> : Read / Write
89
"<a class="link" href="GtkMisc.html#GtkMisc--yalign" title='The "yalign" property'>yalign</a>" <span class="type">gfloat</span> : Read / Write
90
"<a class="link" href="GtkMisc.html#GtkMisc--ypad" title='The "ypad" property'>ypad</a>" <span class="type">gint</span> : Read / Write
93
<div class="refsect1">
94
<a name="GtkMisc.description"></a><h2>Description</h2>
96
The <a class="link" href="GtkMisc.html" title="GtkMisc"><span class="type">GtkMisc</span></a> widget is an abstract widget which is not useful itself, but
97
is used to derive subclasses which have alignment and padding attributes.
100
The horizontal and vertical padding attributes allows extra space to be
101
added around the widget.
104
The horizontal and vertical alignment attributes enable the widget to be
105
positioned within its allocated area. Note that if the widget is added to
106
a container in such a way that it expands automatically to fill its
107
allocated area, the alignment settings will not alter the widgets position.
110
<div class="refsect1">
111
<a name="GtkMisc.details"></a><h2>Details</h2>
112
<div class="refsect2">
113
<a name="GtkMisc-struct"></a><h3>struct GtkMisc</h3>
114
<pre class="programlisting">struct GtkMisc;</pre>
116
The <a class="link" href="GtkMisc.html#GtkMisc-struct" title="struct GtkMisc"><span class="type">GtkMisc</span></a> struct contains the following fields.
117
(These fields should be considered read-only. They should never be set by
120
<div class="informaltable"><table width="100%" border="0">
128
<span class="type">gfloat</span> <em class="structfield"><code>xalign</code></em>;</td>
129
<td>the horizontal alignment, from 0 (left) to 1 (right).</td>
133
<span class="type">gfloat</span> <em class="structfield"><code>yalign</code></em>;</td>
134
<td>the vertical alignment, from 0 (top) to 1 (bottom).</td>
138
<span class="type">guint16</span> <em class="structfield"><code>xpad</code></em>;</td>
139
<td>the amount of space to add on the left and right of the widget,
144
<span class="type">guint16</span> <em class="structfield"><code>ypad</code></em>;</td>
145
<td>the amount of space to add on the top and bottom of the widget,
154
<div class="refsect2">
155
<a name="gtk-misc-set-alignment"></a><h3>gtk_misc_set_alignment ()</h3>
156
<pre class="programlisting"><span class="returnvalue">void</span> gtk_misc_set_alignment (<em class="parameter"><code><a class="link" href="GtkMisc.html" title="GtkMisc"><span class="type">GtkMisc</span></a> *misc</code></em>,
157
<em class="parameter"><code><span class="type">gfloat</span> xalign</code></em>,
158
<em class="parameter"><code><span class="type">gfloat</span> yalign</code></em>);</pre>
160
Sets the alignment of the widget.
162
<div class="variablelist"><table border="0" class="variablelist">
164
<col align="left" valign="top">
169
<td><p><span class="term"><em class="parameter"><code>misc</code></em> :</span></p></td>
170
<td>a <a class="link" href="GtkMisc.html" title="GtkMisc"><span class="type">GtkMisc</span></a>.</td>
173
<td><p><span class="term"><em class="parameter"><code>xalign</code></em> :</span></p></td>
174
<td>the horizontal alignment, from 0 (left) to 1 (right).</td>
177
<td><p><span class="term"><em class="parameter"><code>yalign</code></em> :</span></p></td>
178
<td>the vertical alignment, from 0 (top) to 1 (bottom).</td>
184
<div class="refsect2">
185
<a name="gtk-misc-set-padding"></a><h3>gtk_misc_set_padding ()</h3>
186
<pre class="programlisting"><span class="returnvalue">void</span> gtk_misc_set_padding (<em class="parameter"><code><a class="link" href="GtkMisc.html" title="GtkMisc"><span class="type">GtkMisc</span></a> *misc</code></em>,
187
<em class="parameter"><code><span class="type">gint</span> xpad</code></em>,
188
<em class="parameter"><code><span class="type">gint</span> ypad</code></em>);</pre>
190
Sets the amount of space to add around the widget.
192
<div class="variablelist"><table border="0" class="variablelist">
194
<col align="left" valign="top">
199
<td><p><span class="term"><em class="parameter"><code>misc</code></em> :</span></p></td>
200
<td>a <a class="link" href="GtkMisc.html" title="GtkMisc"><span class="type">GtkMisc</span></a>.</td>
203
<td><p><span class="term"><em class="parameter"><code>xpad</code></em> :</span></p></td>
204
<td>the amount of space to add on the left and right of the widget,
208
<td><p><span class="term"><em class="parameter"><code>ypad</code></em> :</span></p></td>
209
<td>the amount of space to add on the top and bottom of the widget,
216
<div class="refsect2">
217
<a name="gtk-misc-get-alignment"></a><h3>gtk_misc_get_alignment ()</h3>
218
<pre class="programlisting"><span class="returnvalue">void</span> gtk_misc_get_alignment (<em class="parameter"><code><a class="link" href="GtkMisc.html" title="GtkMisc"><span class="type">GtkMisc</span></a> *misc</code></em>,
219
<em class="parameter"><code><span class="type">gfloat</span> *xalign</code></em>,
220
<em class="parameter"><code><span class="type">gfloat</span> *yalign</code></em>);</pre>
222
Gets the X and Y alignment of the widget within its allocation.
223
See <a class="link" href="GtkMisc.html#gtk-misc-set-alignment" title="gtk_misc_set_alignment ()"><code class="function">gtk_misc_set_alignment()</code></a>.
225
<div class="variablelist"><table border="0" class="variablelist">
227
<col align="left" valign="top">
232
<td><p><span class="term"><em class="parameter"><code>misc</code></em> :</span></p></td>
233
<td>a <a class="link" href="GtkMisc.html" title="GtkMisc"><span class="type">GtkMisc</span></a>
237
<td><p><span class="term"><em class="parameter"><code>xalign</code></em> :</span></p></td>
238
<td>location to store X alignment of <em class="parameter"><code>misc</code></em>, or <a href="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
242
<td><p><span class="term"><em class="parameter"><code>yalign</code></em> :</span></p></td>
243
<td>location to store Y alignment of <em class="parameter"><code>misc</code></em>, or <a href="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
250
<div class="refsect2">
251
<a name="gtk-misc-get-padding"></a><h3>gtk_misc_get_padding ()</h3>
252
<pre class="programlisting"><span class="returnvalue">void</span> gtk_misc_get_padding (<em class="parameter"><code><a class="link" href="GtkMisc.html" title="GtkMisc"><span class="type">GtkMisc</span></a> *misc</code></em>,
253
<em class="parameter"><code><span class="type">gint</span> *xpad</code></em>,
254
<em class="parameter"><code><span class="type">gint</span> *ypad</code></em>);</pre>
256
Gets the padding in the X and Y directions of the widget.
257
See <a class="link" href="GtkMisc.html#gtk-misc-set-padding" title="gtk_misc_set_padding ()"><code class="function">gtk_misc_set_padding()</code></a>.
259
<div class="variablelist"><table border="0" class="variablelist">
261
<col align="left" valign="top">
266
<td><p><span class="term"><em class="parameter"><code>misc</code></em> :</span></p></td>
267
<td>a <a class="link" href="GtkMisc.html" title="GtkMisc"><span class="type">GtkMisc</span></a>
271
<td><p><span class="term"><em class="parameter"><code>xpad</code></em> :</span></p></td>
272
<td>location to store padding in the X
273
direction, or <a href="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
277
<td><p><span class="term"><em class="parameter"><code>ypad</code></em> :</span></p></td>
278
<td>location to store padding in the Y
279
direction, or <a href="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
286
<div class="refsect1">
287
<a name="GtkMisc.property-details"></a><h2>Property Details</h2>
288
<div class="refsect2">
289
<a name="GtkMisc--xalign"></a><h3>The <code class="literal">"xalign"</code> property</h3>
290
<pre class="programlisting"> "xalign" <span class="type">gfloat</span> : Read / Write</pre>
291
<p>The horizontal alignment, from 0 (left) to 1 (right). Reversed for RTL layouts.</p>
292
<p>Allowed values: [0,1]</p>
293
<p>Default value: 0.5</p>
296
<div class="refsect2">
297
<a name="GtkMisc--xpad"></a><h3>The <code class="literal">"xpad"</code> property</h3>
298
<pre class="programlisting"> "xpad" <span class="type">gint</span> : Read / Write</pre>
299
<p>The amount of space to add on the left and right of the widget, in pixels.</p>
300
<p>Allowed values: >= 0</p>
301
<p>Default value: 0</p>
304
<div class="refsect2">
305
<a name="GtkMisc--yalign"></a><h3>The <code class="literal">"yalign"</code> property</h3>
306
<pre class="programlisting"> "yalign" <span class="type">gfloat</span> : Read / Write</pre>
307
<p>The vertical alignment, from 0 (top) to 1 (bottom).</p>
308
<p>Allowed values: [0,1]</p>
309
<p>Default value: 0.5</p>
312
<div class="refsect2">
313
<a name="GtkMisc--ypad"></a><h3>The <code class="literal">"ypad"</code> property</h3>
314
<pre class="programlisting"> "ypad" <span class="type">gint</span> : Read / Write</pre>
315
<p>The amount of space to add on the top and bottom of the widget, in pixels.</p>
316
<p>Allowed values: >= 0</p>
317
<p>Default value: 0</p>
323
Generated by GTK-Doc V1.18</div>
b'\\ No newline at end of file'