46
48
<th width="100%" align="center">GObject Reference Manual</th>
47
49
<td><a accesskey="n" href="gobject-Signals.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
49
<tr><td colspan="5" class="shortcuts"><nobr><a href="#id2938263" class="shortcut">Top</a>
51
<a href="#id2940526" class="shortcut">Description</a></nobr></td></tr>
51
<tr><td colspan="5" class="shortcuts">
52
<a href="#gobject-GParamSpec.synopsis" class="shortcut">Top</a>
54
<a href="#gobject-GParamSpec.description" class="shortcut">Description</a>
53
57
<div class="refentry" lang="en">
54
58
<a name="gobject-GParamSpec"></a><div class="titlepage"></div>
55
59
<div class="refnamediv"><table width="100%"><tr>
58
<a name="id2938263"></a><span class="refentrytitle">GParamSpec</span>
60
<p>GParamSpec — Metadata for parameter specifications</p>
61
<h2><span class="refentrytitle"><a name="gobject-GParamSpec.top_of_page"></a>GParamSpec</span></h2>
62
<p>GParamSpec — Metadata for parameter specifications</p>
62
64
<td valign="top" align="right"></td>
63
65
</tr></table></div>
64
66
<div class="refsynopsisdiv">
67
<a name="gobject-GParamSpec.synopsis"></a><h2>Synopsis</h2>
66
68
<pre class="synopsis">
68
70
#include <glib-object.h>
71
#define <a class="link" href="gobject-GParamSpec.html#G-TYPE-IS-PARAM:CAPS">G_TYPE_IS_PARAM</a> (type)
72
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-SPEC:CAPS">G_PARAM_SPEC</a> (pspec)
73
#define <a class="link" href="gobject-GParamSpec.html#G-IS-PARAM-SPEC:CAPS">G_IS_PARAM_SPEC</a> (pspec)
74
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-SPEC-CLASS:CAPS">G_PARAM_SPEC_CLASS</a> (pclass)
75
#define <a class="link" href="gobject-GParamSpec.html#G-IS-PARAM-SPEC-CLASS:CAPS">G_IS_PARAM_SPEC_CLASS</a> (pclass)
76
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-SPEC-GET-CLASS:CAPS">G_PARAM_SPEC_GET_CLASS</a> (pspec)
77
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-SPEC-TYPE:CAPS">G_PARAM_SPEC_TYPE</a> (pspec)
78
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-SPEC-TYPE-NAME:CAPS">G_PARAM_SPEC_TYPE_NAME</a> (pspec)
79
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-SPEC-VALUE-TYPE:CAPS">G_PARAM_SPEC_VALUE_TYPE</a> (pspec)
80
<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a>;
81
<a class="link" href="gobject-GParamSpec.html#GParamSpecClass">GParamSpecClass</a>;
82
enum <a class="link" href="gobject-GParamSpec.html#GParamFlags">GParamFlags</a>;
83
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-READWRITE:CAPS">G_PARAM_READWRITE</a>
84
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-STATIC-STRINGS:CAPS">G_PARAM_STATIC_STRINGS</a>
85
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-MASK:CAPS">G_PARAM_MASK</a>
86
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-USER-SHIFT:CAPS">G_PARAM_USER_SHIFT</a>
87
<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a>* <a class="link" href="gobject-GParamSpec.html#g-param-spec-ref">g_param_spec_ref</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec);
88
void <a class="link" href="gobject-GParamSpec.html#g-param-spec-unref">g_param_spec_unref</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec);
89
void <a class="link" href="gobject-GParamSpec.html#g-param-spec-sink">g_param_spec_sink</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec);
90
<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a>* <a class="link" href="gobject-GParamSpec.html#g-param-spec-ref-sink">g_param_spec_ref_sink</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec);
91
void <a class="link" href="gobject-GParamSpec.html#g-param-value-set-default">g_param_value_set_default</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec,
92
<a class="link" href="gobject-Generic-values.html#GValue">GValue</a> *value);
94
href="./../glib/glib/glib-Basic-Types.html#gboolean"
95
>gboolean</a> <a class="link" href="gobject-GParamSpec.html#g-param-value-defaults">g_param_value_defaults</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec,
96
<a class="link" href="gobject-Generic-values.html#GValue">GValue</a> *value);
98
href="./../glib/glib/glib-Basic-Types.html#gboolean"
99
>gboolean</a> <a class="link" href="gobject-GParamSpec.html#g-param-value-validate">g_param_value_validate</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec,
100
<a class="link" href="gobject-Generic-values.html#GValue">GValue</a> *value);
102
href="./../glib/glib/glib-Basic-Types.html#gboolean"
103
>gboolean</a> <a class="link" href="gobject-GParamSpec.html#g-param-value-convert">g_param_value_convert</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec,
104
const <a class="link" href="gobject-Generic-values.html#GValue">GValue</a> *src_value,
105
<a class="link" href="gobject-Generic-values.html#GValue">GValue</a> *dest_value,
72
#define <a class="link" href="gobject-GParamSpec.html#G-TYPE-IS-PARAM--CAPS" title="G_TYPE_IS_PARAM()">G_TYPE_IS_PARAM</a> (type)
73
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-SPEC--CAPS" title="G_PARAM_SPEC()">G_PARAM_SPEC</a> (pspec)
74
#define <a class="link" href="gobject-GParamSpec.html#G-IS-PARAM-SPEC--CAPS" title="G_IS_PARAM_SPEC()">G_IS_PARAM_SPEC</a> (pspec)
75
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-SPEC-CLASS--CAPS" title="G_PARAM_SPEC_CLASS()">G_PARAM_SPEC_CLASS</a> (pclass)
76
#define <a class="link" href="gobject-GParamSpec.html#G-IS-PARAM-SPEC-CLASS--CAPS" title="G_IS_PARAM_SPEC_CLASS()">G_IS_PARAM_SPEC_CLASS</a> (pclass)
77
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-SPEC-GET-CLASS--CAPS" title="G_PARAM_SPEC_GET_CLASS()">G_PARAM_SPEC_GET_CLASS</a> (pspec)
78
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-SPEC-TYPE--CAPS" title="G_PARAM_SPEC_TYPE()">G_PARAM_SPEC_TYPE</a> (pspec)
79
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-SPEC-TYPE-NAME--CAPS" title="G_PARAM_SPEC_TYPE_NAME()">G_PARAM_SPEC_TYPE_NAME</a> (pspec)
80
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-SPEC-VALUE-TYPE--CAPS" title="G_PARAM_SPEC_VALUE_TYPE()">G_PARAM_SPEC_VALUE_TYPE</a> (pspec)
81
<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a>;
82
<a class="link" href="gobject-GParamSpec.html#GParamSpecClass" title="GParamSpecClass">GParamSpecClass</a>;
83
enum <a class="link" href="gobject-GParamSpec.html#GParamFlags" title="enum GParamFlags">GParamFlags</a>;
84
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-READWRITE--CAPS" title="G_PARAM_READWRITE">G_PARAM_READWRITE</a>
85
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-STATIC-STRINGS--CAPS" title="G_PARAM_STATIC_STRINGS">G_PARAM_STATIC_STRINGS</a>
86
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-MASK--CAPS" title="G_PARAM_MASK">G_PARAM_MASK</a>
87
#define <a class="link" href="gobject-GParamSpec.html#G-PARAM-USER-SHIFT--CAPS" title="G_PARAM_USER_SHIFT">G_PARAM_USER_SHIFT</a>
88
<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a>* <a class="link" href="gobject-GParamSpec.html#g-param-spec-ref" title="g_param_spec_ref ()">g_param_spec_ref</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec);
89
void <a class="link" href="gobject-GParamSpec.html#g-param-spec-unref" title="g_param_spec_unref ()">g_param_spec_unref</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec);
90
void <a class="link" href="gobject-GParamSpec.html#g-param-spec-sink" title="g_param_spec_sink ()">g_param_spec_sink</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec);
91
<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a>* <a class="link" href="gobject-GParamSpec.html#g-param-spec-ref-sink" title="g_param_spec_ref_sink ()">g_param_spec_ref_sink</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec);
92
void <a class="link" href="gobject-GParamSpec.html#g-param-value-set-default" title="g_param_value_set_default ()">g_param_value_set_default</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec,
93
<a class="link" href="gobject-Generic-values.html#GValue" title="GValue">GValue</a> *value);
95
href="./../glib/glib/glib-Basic-Types.html#gboolean"
96
>gboolean</a> <a class="link" href="gobject-GParamSpec.html#g-param-value-defaults" title="g_param_value_defaults ()">g_param_value_defaults</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec,
97
<a class="link" href="gobject-Generic-values.html#GValue" title="GValue">GValue</a> *value);
99
href="./../glib/glib/glib-Basic-Types.html#gboolean"
100
>gboolean</a> <a class="link" href="gobject-GParamSpec.html#g-param-value-validate" title="g_param_value_validate ()">g_param_value_validate</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec,
101
<a class="link" href="gobject-Generic-values.html#GValue" title="GValue">GValue</a> *value);
103
href="./../glib/glib/glib-Basic-Types.html#gboolean"
104
>gboolean</a> <a class="link" href="gobject-GParamSpec.html#g-param-value-convert" title="g_param_value_convert ()">g_param_value_convert</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec,
105
const <a class="link" href="gobject-Generic-values.html#GValue" title="GValue">GValue</a> *src_value,
106
<a class="link" href="gobject-Generic-values.html#GValue" title="GValue">GValue</a> *dest_value,
107
108
href="./../glib/glib/glib-Basic-Types.html#gboolean"
108
109
>gboolean</a> strict_validation);
110
111
href="./../glib/glib/glib-Basic-Types.html#gint"
111
>gint</a> <a class="link" href="gobject-GParamSpec.html#g-param-values-cmp">g_param_values_cmp</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec,
112
const <a class="link" href="gobject-Generic-values.html#GValue">GValue</a> *value1,
113
const <a class="link" href="gobject-Generic-values.html#GValue">GValue</a> *value2);
115
href="./../glib/glib/glib-Basic-Types.html#gchar"
116
>gchar</a>* <a class="link" href="gobject-GParamSpec.html#g-param-spec-get-name">g_param_spec_get_name</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec);
118
href="./../glib/glib/glib-Basic-Types.html#gchar"
119
>gchar</a>* <a class="link" href="gobject-GParamSpec.html#g-param-spec-get-nick">g_param_spec_get_nick</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec);
121
href="./../glib/glib/glib-Basic-Types.html#gchar"
122
>gchar</a>* <a class="link" href="gobject-GParamSpec.html#g-param-spec-get-blurb">g_param_spec_get_blurb</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec);
112
>gint</a> <a class="link" href="gobject-GParamSpec.html#g-param-values-cmp" title="g_param_values_cmp ()">g_param_values_cmp</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec,
113
const <a class="link" href="gobject-Generic-values.html#GValue" title="GValue">GValue</a> *value1,
114
const <a class="link" href="gobject-Generic-values.html#GValue" title="GValue">GValue</a> *value2);
116
href="./../glib/glib/glib-Basic-Types.html#gchar"
117
>gchar</a>* <a class="link" href="gobject-GParamSpec.html#g-param-spec-get-name" title="g_param_spec_get_name ()">g_param_spec_get_name</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec);
119
href="./../glib/glib/glib-Basic-Types.html#gchar"
120
>gchar</a>* <a class="link" href="gobject-GParamSpec.html#g-param-spec-get-nick" title="g_param_spec_get_nick ()">g_param_spec_get_nick</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec);
122
href="./../glib/glib/glib-Basic-Types.html#gchar"
123
>gchar</a>* <a class="link" href="gobject-GParamSpec.html#g-param-spec-get-blurb" title="g_param_spec_get_blurb ()">g_param_spec_get_blurb</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec);
124
125
href="./../glib/glib/glib-Basic-Types.html#gpointer"
125
>gpointer</a> <a class="link" href="gobject-GParamSpec.html#g-param-spec-get-qdata">g_param_spec_get_qdata</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec,
126
>gpointer</a> <a class="link" href="gobject-GParamSpec.html#g-param-spec-get-qdata" title="g_param_spec_get_qdata ()">g_param_spec_get_qdata</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec,
127
128
href="./../glib/glib/glib-Quarks.html#GQuark"
128
129
>GQuark</a> quark);
129
void <a class="link" href="gobject-GParamSpec.html#g-param-spec-set-qdata">g_param_spec_set_qdata</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec,
130
void <a class="link" href="gobject-GParamSpec.html#g-param-spec-set-qdata" title="g_param_spec_set_qdata ()">g_param_spec_set_qdata</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec,
131
132
href="./../glib/glib/glib-Quarks.html#GQuark"
132
133
>GQuark</a> quark,
134
135
href="./../glib/glib/glib-Basic-Types.html#gpointer"
135
136
>gpointer</a> data);
136
void <a class="link" href="gobject-GParamSpec.html#g-param-spec-set-qdata-full">g_param_spec_set_qdata_full</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec,
137
void <a class="link" href="gobject-GParamSpec.html#g-param-spec-set-qdata-full" title="g_param_spec_set_qdata_full ()">g_param_spec_set_qdata_full</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec,
138
139
href="./../glib/glib/glib-Quarks.html#GQuark"
139
140
>GQuark</a> quark,
163
164
href="./../glib/glib/glib-Basic-Types.html#gchar"
164
165
>gchar</a> *blurb,
165
<a class="link" href="gobject-GParamSpec.html#GParamFlags">GParamFlags</a> flags);
166
<a class="link" href="gobject-GParamSpec.html#GParamSpecTypeInfo">GParamSpecTypeInfo</a>;
167
<a class="link" href="gobject-Type-Information.html#GType">GType</a> <a class="link" href="gobject-GParamSpec.html#g-param-type-register-static">g_param_type_register_static</a> (const <a
166
<a class="link" href="gobject-GParamSpec.html#GParamFlags" title="enum GParamFlags">GParamFlags</a> flags);
167
<a class="link" href="gobject-GParamSpec.html#GParamSpecTypeInfo" title="GParamSpecTypeInfo">GParamSpecTypeInfo</a>;
168
<a class="link" href="gobject-Type-Information.html#GType" title="GType">GType</a> <a class="link" href="gobject-GParamSpec.html#g-param-type-register-static" title="g_param_type_register_static ()">g_param_type_register_static</a> (const <a
168
169
href="./../glib/glib/glib-Basic-Types.html#gchar"
169
170
>gchar</a> *name,
170
const <a class="link" href="gobject-GParamSpec.html#GParamSpecTypeInfo">GParamSpecTypeInfo</a> *pspec_info);
171
<a class="link" href="gobject-GParamSpec.html#GParamSpecPool">GParamSpecPool</a>;
172
<a class="link" href="gobject-GParamSpec.html#GParamSpecPool">GParamSpecPool</a>* <a class="link" href="gobject-GParamSpec.html#g-param-spec-pool-new">g_param_spec_pool_new</a> (<a
171
const <a class="link" href="gobject-GParamSpec.html#GParamSpecTypeInfo" title="GParamSpecTypeInfo">GParamSpecTypeInfo</a> *pspec_info);
172
<a class="link" href="gobject-GParamSpec.html#GParamSpecPool" title="GParamSpecPool">GParamSpecPool</a>;
173
<a class="link" href="gobject-GParamSpec.html#GParamSpecPool" title="GParamSpecPool">GParamSpecPool</a>* <a class="link" href="gobject-GParamSpec.html#g-param-spec-pool-new" title="g_param_spec_pool_new ()">g_param_spec_pool_new</a> (<a
173
174
href="./../glib/glib/glib-Basic-Types.html#gboolean"
174
175
>gboolean</a> type_prefixing);
175
void <a class="link" href="gobject-GParamSpec.html#g-param-spec-pool-insert">g_param_spec_pool_insert</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpecPool">GParamSpecPool</a> *pool,
176
<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec,
177
<a class="link" href="gobject-Type-Information.html#GType">GType</a> owner_type);
178
void <a class="link" href="gobject-GParamSpec.html#g-param-spec-pool-remove">g_param_spec_pool_remove</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpecPool">GParamSpecPool</a> *pool,
179
<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec);
180
<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a>* <a class="link" href="gobject-GParamSpec.html#g-param-spec-pool-lookup">g_param_spec_pool_lookup</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpecPool">GParamSpecPool</a> *pool,
176
void <a class="link" href="gobject-GParamSpec.html#g-param-spec-pool-insert" title="g_param_spec_pool_insert ()">g_param_spec_pool_insert</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpecPool" title="GParamSpecPool">GParamSpecPool</a> *pool,
177
<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec,
178
<a class="link" href="gobject-Type-Information.html#GType" title="GType">GType</a> owner_type);
179
void <a class="link" href="gobject-GParamSpec.html#g-param-spec-pool-remove" title="g_param_spec_pool_remove ()">g_param_spec_pool_remove</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpecPool" title="GParamSpecPool">GParamSpecPool</a> *pool,
180
<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec);
181
<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a>* <a class="link" href="gobject-GParamSpec.html#g-param-spec-pool-lookup" title="g_param_spec_pool_lookup ()">g_param_spec_pool_lookup</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpecPool" title="GParamSpecPool">GParamSpecPool</a> *pool,
182
183
href="./../glib/glib/glib-Basic-Types.html#gchar"
183
184
>gchar</a> *param_name,
184
<a class="link" href="gobject-Type-Information.html#GType">GType</a> owner_type,
185
<a class="link" href="gobject-Type-Information.html#GType" title="GType">GType</a> owner_type,
186
187
href="./../glib/glib/glib-Basic-Types.html#gboolean"
187
188
>gboolean</a> walk_ancestors);
188
<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a>** <a class="link" href="gobject-GParamSpec.html#g-param-spec-pool-list">g_param_spec_pool_list</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpecPool">GParamSpecPool</a> *pool,
189
<a class="link" href="gobject-Type-Information.html#GType">GType</a> owner_type,
189
<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a>** <a class="link" href="gobject-GParamSpec.html#g-param-spec-pool-list" title="g_param_spec_pool_list ()">g_param_spec_pool_list</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpecPool" title="GParamSpecPool">GParamSpecPool</a> *pool,
190
<a class="link" href="gobject-Type-Information.html#GType" title="GType">GType</a> owner_type,
191
192
href="./../glib/glib/glib-Basic-Types.html#guint"
192
193
>guint</a> *n_pspecs_p);
194
195
href="./../glib/glib/glib-Doubly-Linked-Lists.html#GList"
195
>GList</a>* <a class="link" href="gobject-GParamSpec.html#g-param-spec-pool-list-owned">g_param_spec_pool_list_owned</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpecPool">GParamSpecPool</a> *pool,
196
<a class="link" href="gobject-Type-Information.html#GType">GType</a> owner_type);
196
>GList</a>* <a class="link" href="gobject-GParamSpec.html#g-param-spec-pool-list-owned" title="g_param_spec_pool_list_owned ()">g_param_spec_pool_list_owned</a> (<a class="link" href="gobject-GParamSpec.html#GParamSpecPool" title="GParamSpecPool">GParamSpecPool</a> *pool,
197
<a class="link" href="gobject-Type-Information.html#GType" title="GType">GType</a> owner_type);
199
200
<div class="refsect1" lang="en">
200
<a name="id2940526"></a><h2>Description</h2>
201
<a name="gobject-GParamSpec.description"></a><h2>Description</h2>
202
<a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a> is an object structure that encapsulates the metadata
203
<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a> is an object structure that encapsulates the metadata
203
204
required to specify parameters, such as e.g. <a class="link" href="gobject-The-Base-Object-Type.html#GObject"><span class="type">GObject</span></a> properties.
205
208
<p><a name="canonical-parameter-name"></a>
206
209
Parameter names need to start with a letter (a-z or A-Z). Subsequent
207
210
characters can be letters, numbers or a '-'.
209
212
The result of this replacement is called the canonical name of the
213
218
<div class="refsect1" lang="en">
214
<a name="id2940570"></a><h2>Details</h2>
215
<div class="refsect2" lang="en">
216
<a name="id2940581"></a><h3>
217
<a name="G-TYPE-IS-PARAM:CAPS"></a>G_TYPE_IS_PARAM()</h3>
218
<a class="indexterm" name="id2940593"></a><pre class="programlisting">#define G_TYPE_IS_PARAM(type) (G_TYPE_FUNDAMENTAL (type) == G_TYPE_PARAM)
221
Returns whether <em class="parameter"><code>type</code></em> "is a" <a class="link" href="gobject-Type-Information.html#G-TYPE-PARAM:CAPS"><code class="literal">G_TYPE_PARAM</code></a>.
223
<div class="variablelist"><table border="0">
224
<col align="left" valign="top">
226
<td><p><span class="term"><em class="parameter"><code>type</code></em> :</span></p></td>
227
<td>a <a class="link" href="gobject-Type-Information.html#GType"><span class="type">GType</span></a> ID
235
<div class="refsect2" lang="en">
236
<a name="id2940652"></a><h3>
237
<a name="G-PARAM-SPEC:CAPS"></a>G_PARAM_SPEC()</h3>
238
<a class="indexterm" name="id2940664"></a><pre class="programlisting">#define G_PARAM_SPEC(pspec) (G_TYPE_CHECK_INSTANCE_CAST ((pspec), G_TYPE_PARAM, GParamSpec))
241
Casts a derived <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a> object (e.g. of type <a class="link" href="gobject-Standard-Parameter-and-Value-Types.html#GParamSpecInt"><span class="type">GParamSpecInt</span></a>) into
242
a <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a> object.
244
<div class="variablelist"><table border="0">
245
<col align="left" valign="top">
247
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
248
<td>a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
256
<div class="refsect2" lang="en">
257
<a name="id2940732"></a><h3>
258
<a name="G-IS-PARAM-SPEC:CAPS"></a>G_IS_PARAM_SPEC()</h3>
259
<a class="indexterm" name="id2940745"></a><pre class="programlisting">#define G_IS_PARAM_SPEC(pspec) (G_TYPE_CHECK_INSTANCE_TYPE ((pspec), G_TYPE_PARAM))
262
Checks whether <em class="parameter"><code>pspec</code></em> "is a" valid <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a> structure of type <a class="link" href="gobject-Type-Information.html#G-TYPE-PARAM:CAPS"><code class="literal">G_TYPE_PARAM</code></a>
265
<div class="variablelist"><table border="0">
266
<col align="left" valign="top">
268
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
269
<td>a <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
277
<div class="refsect2" lang="en">
278
<a name="id2940813"></a><h3>
279
<a name="G-PARAM-SPEC-CLASS:CAPS"></a>G_PARAM_SPEC_CLASS()</h3>
280
<a class="indexterm" name="id2940826"></a><pre class="programlisting">#define G_PARAM_SPEC_CLASS(pclass) (G_TYPE_CHECK_CLASS_CAST ((pclass), G_TYPE_PARAM, GParamSpecClass))
283
Casts a derived <a class="link" href="gobject-GParamSpec.html#GParamSpecClass"><span class="type">GParamSpecClass</span></a> structure into a <a class="link" href="gobject-GParamSpec.html#GParamSpecClass"><span class="type">GParamSpecClass</span></a> structure.
285
<div class="variablelist"><table border="0">
286
<col align="left" valign="top">
288
<td><p><span class="term"><em class="parameter"><code>pclass</code></em> :</span></p></td>
289
<td>a valid <a class="link" href="gobject-GParamSpec.html#GParamSpecClass"><span class="type">GParamSpecClass</span></a>
297
<div class="refsect2" lang="en">
298
<a name="id2940886"></a><h3>
299
<a name="G-IS-PARAM-SPEC-CLASS:CAPS"></a>G_IS_PARAM_SPEC_CLASS()</h3>
300
<a class="indexterm" name="id2940899"></a><pre class="programlisting">#define G_IS_PARAM_SPEC_CLASS(pclass) (G_TYPE_CHECK_CLASS_TYPE ((pclass), G_TYPE_PARAM))
303
Checks whether <em class="parameter"><code>pclass</code></em> "is a" valid <a class="link" href="gobject-GParamSpec.html#GParamSpecClass"><span class="type">GParamSpecClass</span></a> structure of type
304
<a class="link" href="gobject-Type-Information.html#G-TYPE-PARAM:CAPS"><code class="literal">G_TYPE_PARAM</code></a> or derived.
306
<div class="variablelist"><table border="0">
307
<col align="left" valign="top">
309
<td><p><span class="term"><em class="parameter"><code>pclass</code></em> :</span></p></td>
310
<td>a <a class="link" href="gobject-GParamSpec.html#GParamSpecClass"><span class="type">GParamSpecClass</span></a>
318
<div class="refsect2" lang="en">
319
<a name="id2940968"></a><h3>
320
<a name="G-PARAM-SPEC-GET-CLASS:CAPS"></a>G_PARAM_SPEC_GET_CLASS()</h3>
321
<a class="indexterm" name="id2940981"></a><pre class="programlisting">#define G_PARAM_SPEC_GET_CLASS(pspec) (G_TYPE_INSTANCE_GET_CLASS ((pspec), G_TYPE_PARAM, GParamSpecClass))
324
Retrieves the <a class="link" href="gobject-GParamSpec.html#GParamSpecClass"><span class="type">GParamSpecClass</span></a> of a <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>.
326
<div class="variablelist"><table border="0">
327
<col align="left" valign="top">
329
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
330
<td>a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
338
<div class="refsect2" lang="en">
339
<a name="id2941040"></a><h3>
340
<a name="G-PARAM-SPEC-TYPE:CAPS"></a>G_PARAM_SPEC_TYPE()</h3>
341
<a class="indexterm" name="id2941054"></a><pre class="programlisting">#define G_PARAM_SPEC_TYPE(pspec) (G_TYPE_FROM_INSTANCE (pspec))
344
Retrieves the <a class="link" href="gobject-Type-Information.html#GType"><span class="type">GType</span></a> of this <em class="parameter"><code>pspec</code></em>.
346
<div class="variablelist"><table border="0">
347
<col align="left" valign="top">
349
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
350
<td>a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
358
<div class="refsect2" lang="en">
359
<a name="id2941110"></a><h3>
360
<a name="G-PARAM-SPEC-TYPE-NAME:CAPS"></a>G_PARAM_SPEC_TYPE_NAME()</h3>
361
<a class="indexterm" name="id2941122"></a><pre class="programlisting">#define G_PARAM_SPEC_TYPE_NAME(pspec) (g_type_name (G_PARAM_SPEC_TYPE (pspec)))
364
Retrieves the <a class="link" href="gobject-Type-Information.html#GType"><span class="type">GType</span></a> name of this <em class="parameter"><code>pspec</code></em>.
366
<div class="variablelist"><table border="0">
367
<col align="left" valign="top">
369
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
370
<td>a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
378
<div class="refsect2" lang="en">
379
<a name="id2941179"></a><h3>
380
<a name="G-PARAM-SPEC-VALUE-TYPE:CAPS"></a>G_PARAM_SPEC_VALUE_TYPE()</h3>
381
<a class="indexterm" name="id2941193"></a><pre class="programlisting">#define G_PARAM_SPEC_VALUE_TYPE(pspec) (G_PARAM_SPEC (pspec)->value_type)
384
Retrieves the <a class="link" href="gobject-Type-Information.html#GType"><span class="type">GType</span></a> to initialize a <a class="link" href="gobject-Generic-values.html#GValue"><span class="type">GValue</span></a> for this parameter.
386
<div class="variablelist"><table border="0">
387
<col align="left" valign="top">
389
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
390
<td>a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
398
<div class="refsect2" lang="en">
399
<a name="id2941253"></a><h3>
400
<a name="GParamSpec"></a>GParamSpec</h3>
401
<a class="indexterm" name="id2941265"></a><pre class="programlisting">typedef struct {
219
<a name="gobject-GParamSpec.details"></a><h2>Details</h2>
220
<div class="refsect2" lang="en">
221
<a name="G-TYPE-IS-PARAM--CAPS"></a><h3>G_TYPE_IS_PARAM()</h3>
222
<pre class="programlisting">#define G_TYPE_IS_PARAM(type) (G_TYPE_FUNDAMENTAL (type) == G_TYPE_PARAM)
225
Checks whether <em class="parameter"><code>type</code></em> "is a" <a class="link" href="gobject-Type-Information.html#G-TYPE-PARAM--CAPS" title="G_TYPE_PARAM"><code class="literal">G_TYPE_PARAM</code></a>.</p>
228
<div class="variablelist"><table border="0">
229
<col align="left" valign="top">
231
<td><p><span class="term"><em class="parameter"><code>type</code></em> :</span></p></td>
232
<td> a <a class="link" href="gobject-Type-Information.html#GType" title="GType"><span class="type">GType</span></a> ID
238
<div class="refsect2" lang="en">
239
<a name="G-PARAM-SPEC--CAPS"></a><h3>G_PARAM_SPEC()</h3>
240
<pre class="programlisting">#define G_PARAM_SPEC(pspec) (G_TYPE_CHECK_INSTANCE_CAST ((pspec), G_TYPE_PARAM, GParamSpec))
243
Casts a derived <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a> object (e.g. of type <a class="link" href="gobject-Standard-Parameter-and-Value-Types.html#GParamSpecInt" title="GParamSpecInt"><span class="type">GParamSpecInt</span></a>) into
244
a <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a> object.</p>
247
<div class="variablelist"><table border="0">
248
<col align="left" valign="top">
250
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
251
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
257
<div class="refsect2" lang="en">
258
<a name="G-IS-PARAM-SPEC--CAPS"></a><h3>G_IS_PARAM_SPEC()</h3>
259
<pre class="programlisting">#define G_IS_PARAM_SPEC(pspec) (G_TYPE_CHECK_INSTANCE_TYPE ((pspec), G_TYPE_PARAM))
262
Checks whether <em class="parameter"><code>pspec</code></em> "is a" valid <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a> structure of type <a class="link" href="gobject-Type-Information.html#G-TYPE-PARAM--CAPS" title="G_TYPE_PARAM"><code class="literal">G_TYPE_PARAM</code></a>
266
<div class="variablelist"><table border="0">
267
<col align="left" valign="top">
269
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
270
<td> a <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
276
<div class="refsect2" lang="en">
277
<a name="G-PARAM-SPEC-CLASS--CAPS"></a><h3>G_PARAM_SPEC_CLASS()</h3>
278
<pre class="programlisting">#define G_PARAM_SPEC_CLASS(pclass) (G_TYPE_CHECK_CLASS_CAST ((pclass), G_TYPE_PARAM, GParamSpecClass))
281
Casts a derived <a class="link" href="gobject-GParamSpec.html#GParamSpecClass" title="GParamSpecClass"><span class="type">GParamSpecClass</span></a> structure into a <a class="link" href="gobject-GParamSpec.html#GParamSpecClass" title="GParamSpecClass"><span class="type">GParamSpecClass</span></a> structure.</p>
284
<div class="variablelist"><table border="0">
285
<col align="left" valign="top">
287
<td><p><span class="term"><em class="parameter"><code>pclass</code></em> :</span></p></td>
288
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpecClass" title="GParamSpecClass"><span class="type">GParamSpecClass</span></a>
294
<div class="refsect2" lang="en">
295
<a name="G-IS-PARAM-SPEC-CLASS--CAPS"></a><h3>G_IS_PARAM_SPEC_CLASS()</h3>
296
<pre class="programlisting">#define G_IS_PARAM_SPEC_CLASS(pclass) (G_TYPE_CHECK_CLASS_TYPE ((pclass), G_TYPE_PARAM))
299
Checks whether <em class="parameter"><code>pclass</code></em> "is a" valid <a class="link" href="gobject-GParamSpec.html#GParamSpecClass" title="GParamSpecClass"><span class="type">GParamSpecClass</span></a> structure of type
300
<a class="link" href="gobject-Type-Information.html#G-TYPE-PARAM--CAPS" title="G_TYPE_PARAM"><code class="literal">G_TYPE_PARAM</code></a> or derived.</p>
303
<div class="variablelist"><table border="0">
304
<col align="left" valign="top">
306
<td><p><span class="term"><em class="parameter"><code>pclass</code></em> :</span></p></td>
307
<td> a <a class="link" href="gobject-GParamSpec.html#GParamSpecClass" title="GParamSpecClass"><span class="type">GParamSpecClass</span></a>
313
<div class="refsect2" lang="en">
314
<a name="G-PARAM-SPEC-GET-CLASS--CAPS"></a><h3>G_PARAM_SPEC_GET_CLASS()</h3>
315
<pre class="programlisting">#define G_PARAM_SPEC_GET_CLASS(pspec) (G_TYPE_INSTANCE_GET_CLASS ((pspec), G_TYPE_PARAM, GParamSpecClass))
318
Retrieves the <a class="link" href="gobject-GParamSpec.html#GParamSpecClass" title="GParamSpecClass"><span class="type">GParamSpecClass</span></a> of a <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>.</p>
321
<div class="variablelist"><table border="0">
322
<col align="left" valign="top">
324
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
325
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
331
<div class="refsect2" lang="en">
332
<a name="G-PARAM-SPEC-TYPE--CAPS"></a><h3>G_PARAM_SPEC_TYPE()</h3>
333
<pre class="programlisting">#define G_PARAM_SPEC_TYPE(pspec) (G_TYPE_FROM_INSTANCE (pspec))
336
Retrieves the <a class="link" href="gobject-Type-Information.html#GType" title="GType"><span class="type">GType</span></a> of this <em class="parameter"><code>pspec</code></em>.</p>
339
<div class="variablelist"><table border="0">
340
<col align="left" valign="top">
342
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
343
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
349
<div class="refsect2" lang="en">
350
<a name="G-PARAM-SPEC-TYPE-NAME--CAPS"></a><h3>G_PARAM_SPEC_TYPE_NAME()</h3>
351
<pre class="programlisting">#define G_PARAM_SPEC_TYPE_NAME(pspec) (g_type_name (G_PARAM_SPEC_TYPE (pspec)))
354
Retrieves the <a class="link" href="gobject-Type-Information.html#GType" title="GType"><span class="type">GType</span></a> name of this <em class="parameter"><code>pspec</code></em>.</p>
357
<div class="variablelist"><table border="0">
358
<col align="left" valign="top">
360
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
361
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
367
<div class="refsect2" lang="en">
368
<a name="G-PARAM-SPEC-VALUE-TYPE--CAPS"></a><h3>G_PARAM_SPEC_VALUE_TYPE()</h3>
369
<pre class="programlisting">#define G_PARAM_SPEC_VALUE_TYPE(pspec) (G_PARAM_SPEC (pspec)->value_type)
372
Retrieves the <a class="link" href="gobject-Type-Information.html#GType" title="GType"><span class="type">GType</span></a> to initialize a <a class="link" href="gobject-Generic-values.html#GValue" title="GValue"><span class="type">GValue</span></a> for this parameter.</p>
375
<div class="variablelist"><table border="0">
376
<col align="left" valign="top">
378
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
379
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
385
<div class="refsect2" lang="en">
386
<a name="GParamSpec"></a><h3>GParamSpec</h3>
387
<pre class="programlisting">typedef struct {
402
388
GTypeInstance g_type_instance;
470
455
The class structure for the <span class="structname">GParamSpec</span> type.
471
456
Normally, <span class="structname">GParamSpec</span> classes are filled by
472
<a class="link" href="gobject-GParamSpec.html#g-param-type-register-static"><code class="function">g_param_type_register_static()</code></a>.
457
<a class="link" href="gobject-GParamSpec.html#g-param-type-register-static" title="g_param_type_register_static ()"><code class="function">g_param_type_register_static()</code></a>.</p>
474
460
<div class="variablelist"><table border="0">
475
461
<col align="left" valign="top">
478
<td><p><span class="term"><a class="link" href="gobject-Type-Information.html#GTypeClass">GTypeClass</a> <em class="structfield"><code>g_type_class</code></em>;</span></p></td>
483
<td><p><span class="term"><a class="link" href="gobject-Type-Information.html#GType">GType</a> <em class="structfield"><code>value_type</code></em>;</span></p></td>
484
<td>the <a class="link" href="gobject-Generic-values.html#GValue"><span class="type">GValue</span></a> type for this parameter
488
<td><p><span class="term"><em class="structfield"><code>finalize</code></em> ()</span></p></td>
489
<td>The instance finalization function (optional), should chain
490
up to the finalize method of the parent class.
494
<td><p><span class="term"><em class="structfield"><code>value_set_default</code></em> ()</span></p></td>
495
<td>Resets a <em class="parameter"><code>value</code></em> to the default value for this type
496
(recommended, the default is <a class="link" href="gobject-Generic-values.html#g-value-reset"><code class="function">g_value_reset()</code></a>), see
497
<a class="link" href="gobject-GParamSpec.html#g-param-value-set-default"><code class="function">g_param_value_set_default()</code></a>.
501
<td><p><span class="term"><em class="structfield"><code>value_validate</code></em> ()</span></p></td>
502
<td>Ensures that the contents of <em class="parameter"><code>value</code></em> comply with the
503
specifications set out by this type (optional), see
504
<code class="function">g_param_value_set_validate()</code>.
508
<td><p><span class="term"><em class="structfield"><code>values_cmp</code></em> ()</span></p></td>
509
<td>Compares <em class="parameter"><code>value1</code></em> with <em class="parameter"><code>value2</code></em> according to this type
510
(recommended, the default is <code class="function">memcmp()</code>), see <a class="link" href="gobject-GParamSpec.html#g-param-values-cmp"><code class="function">g_param_values_cmp()</code></a>.
464
<td><p><span class="term"><a class="link" href="gobject-Type-Information.html#GTypeClass" title="GTypeClass">GTypeClass</a> <em class="structfield"><code>g_type_class</code></em>;</span></p></td>
465
<td> the parent class
469
<td><p><span class="term"><a class="link" href="gobject-Type-Information.html#GType" title="GType">GType</a> <em class="structfield"><code>value_type</code></em>;</span></p></td>
470
<td> the <a class="link" href="gobject-Generic-values.html#GValue" title="GValue"><span class="type">GValue</span></a> type for this parameter
474
<td><p><span class="term"><em class="structfield"><code>finalize</code></em> ()</span></p></td>
475
<td> The instance finalization function (optional), should chain
476
up to the finalize method of the parent class.
480
<td><p><span class="term"><em class="structfield"><code>value_set_default</code></em> ()</span></p></td>
481
<td> Resets a <em class="parameter"><code>value</code></em> to the default value for this type
482
(recommended, the default is <a class="link" href="gobject-Generic-values.html#g-value-reset" title="g_value_reset ()"><code class="function">g_value_reset()</code></a>), see
483
<a class="link" href="gobject-GParamSpec.html#g-param-value-set-default" title="g_param_value_set_default ()"><code class="function">g_param_value_set_default()</code></a>.
487
<td><p><span class="term"><em class="structfield"><code>value_validate</code></em> ()</span></p></td>
488
<td> Ensures that the contents of <em class="parameter"><code>value</code></em> comply with the
489
specifications set out by this type (optional), see
490
<code class="function">g_param_value_set_validate()</code>.
494
<td><p><span class="term"><em class="structfield"><code>values_cmp</code></em> ()</span></p></td>
495
<td> Compares <em class="parameter"><code>value1</code></em> with <em class="parameter"><code>value2</code></em> according to this type
496
(recommended, the default is <code class="function">memcmp()</code>), see <a class="link" href="gobject-GParamSpec.html#g-param-values-cmp" title="g_param_values_cmp ()"><code class="function">g_param_values_cmp()</code></a>.
537
Through the <a class="link" href="gobject-GParamSpec.html#GParamFlags"><span class="type">GParamFlags</span></a> flag values, certain aspects of parameters
521
Through the <a class="link" href="gobject-GParamSpec.html#GParamFlags" title="enum GParamFlags"><span class="type">GParamFlags</span></a> flag values, certain aspects of parameters
522
can be configured.</p>
540
525
<div class="variablelist"><table border="0">
541
526
<col align="left" valign="top">
544
<td><p><span class="term"><a name="G-PARAM-READABLE:CAPS"></a><code class="literal">G_PARAM_READABLE</code></span></p></td>
545
<td> the parameter is readable
549
<td><p><span class="term"><a name="G-PARAM-WRITABLE:CAPS"></a><code class="literal">G_PARAM_WRITABLE</code></span></p></td>
550
<td> the parameter is writable
554
<td><p><span class="term"><a name="G-PARAM-CONSTRUCT:CAPS"></a><code class="literal">G_PARAM_CONSTRUCT</code></span></p></td>
555
<td> the parameter will be set upon object construction
559
<td><p><span class="term"><a name="G-PARAM-CONSTRUCT-ONLY:CAPS"></a><code class="literal">G_PARAM_CONSTRUCT_ONLY</code></span></p></td>
560
<td>the parameter will only be set upon object construction
564
<td><p><span class="term"><a name="G-PARAM-LAX-VALIDATION:CAPS"></a><code class="literal">G_PARAM_LAX_VALIDATION</code></span></p></td>
565
<td>upon parameter conversion (see <a class="link" href="gobject-GParamSpec.html#g-param-value-convert"><code class="function">g_param_value_convert()</code></a>)
566
strict validation is not required
570
<td><p><span class="term"><a name="G-PARAM-STATIC-NAME:CAPS"></a><code class="literal">G_PARAM_STATIC_NAME</code></span></p></td>
571
<td> the string used as name when constructing the
572
parameter is guaranteed to remain valid and
573
unmodified for the lifetime of the parameter.
578
<td><p><span class="term"><a name="G-PARAM-PRIVATE:CAPS"></a><code class="literal">G_PARAM_PRIVATE</code></span></p></td>
583
<td><p><span class="term"><a name="G-PARAM-STATIC-NICK:CAPS"></a><code class="literal">G_PARAM_STATIC_NICK</code></span></p></td>
588
<td><p><span class="term"><a name="G-PARAM-STATIC-BLURB:CAPS"></a><code class="literal">G_PARAM_STATIC_BLURB</code></span></p></td>
589
<td> the string used as blurb when constructing the
590
parameter is guaranteed to remain valid and
591
unmodified for the lifetime of the parameter.
529
<td><p><a name="G-PARAM-READABLE--CAPS"></a><span class="term"><code class="literal">G_PARAM_READABLE</code></span></p></td>
530
<td> the parameter is readable
534
<td><p><a name="G-PARAM-WRITABLE--CAPS"></a><span class="term"><code class="literal">G_PARAM_WRITABLE</code></span></p></td>
535
<td> the parameter is writable
539
<td><p><a name="G-PARAM-CONSTRUCT--CAPS"></a><span class="term"><code class="literal">G_PARAM_CONSTRUCT</code></span></p></td>
540
<td> the parameter will be set upon object construction
544
<td><p><a name="G-PARAM-CONSTRUCT-ONLY--CAPS"></a><span class="term"><code class="literal">G_PARAM_CONSTRUCT_ONLY</code></span></p></td>
545
<td> the parameter will only be set upon object construction
549
<td><p><a name="G-PARAM-LAX-VALIDATION--CAPS"></a><span class="term"><code class="literal">G_PARAM_LAX_VALIDATION</code></span></p></td>
550
<td> upon parameter conversion (see <a class="link" href="gobject-GParamSpec.html#g-param-value-convert" title="g_param_value_convert ()"><code class="function">g_param_value_convert()</code></a>)
551
strict validation is not required
555
<td><p><a name="G-PARAM-STATIC-NAME--CAPS"></a><span class="term"><code class="literal">G_PARAM_STATIC_NAME</code></span></p></td>
556
<td> the string used as name when constructing the
557
parameter is guaranteed to remain valid and
558
unmodified for the lifetime of the parameter.
563
<td><p><a name="G-PARAM-PRIVATE--CAPS"></a><span class="term"><code class="literal">G_PARAM_PRIVATE</code></span></p></td>
568
<td><p><a name="G-PARAM-STATIC-NICK--CAPS"></a><span class="term"><code class="literal">G_PARAM_STATIC_NICK</code></span></p></td>
569
<td> the string used as nick when constructing the
570
parameter is guaranteed to remain valid and
571
unmmodified for the lifetime of the parameter.
576
<td><p><a name="G-PARAM-STATIC-BLURB--CAPS"></a><span class="term"><code class="literal">G_PARAM_STATIC_BLURB</code></span></p></td>
577
<td> the string used as blurb when constructing the
578
parameter is guaranteed to remain valid and
579
unmodified for the lifetime of the parameter.
600
587
<div class="refsect2" lang="en">
601
<a name="id2941954"></a><h3>
602
<a name="G-PARAM-READWRITE:CAPS"></a>G_PARAM_READWRITE</h3>
603
<a class="indexterm" name="id2941968"></a><pre class="programlisting">#define G_PARAM_READWRITE (G_PARAM_READABLE | G_PARAM_WRITABLE)
606
<a class="link" href="gobject-GParamSpec.html#GParamFlags"><span class="type">GParamFlags</span></a> value alias for <a class="link" href="gobject-GParamSpec.html#G-PARAM-READABLE:CAPS"><code class="literal">G_PARAM_READABLE</code></a> | <a class="link" href="gobject-GParamSpec.html#G-PARAM-WRITABLE:CAPS"><code class="literal">G_PARAM_WRITABLE</code></a>.
610
<div class="refsect2" lang="en">
611
<a name="id2942015"></a><h3>
612
<a name="G-PARAM-STATIC-STRINGS:CAPS"></a>G_PARAM_STATIC_STRINGS</h3>
613
<a class="indexterm" name="id2942028"></a><pre class="programlisting">#define G_PARAM_STATIC_STRINGS (G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB)
616
<a class="link" href="gobject-GParamSpec.html#GParamFlags"><span class="type">GParamFlags</span></a> value alias for <a class="link" href="gobject-GParamSpec.html#G-PARAM-STATIC-NAME:CAPS"><code class="literal">G_PARAM_STATIC_NAME</code></a> | <a class="link" href="gobject-GParamSpec.html#G-PARAM-STATIC-NICK:CAPS"><code class="literal">G_PARAM_STATIC_NICK</code></a> | <a class="link" href="gobject-GParamSpec.html#G-PARAM-STATIC-BLURB:CAPS"><code class="literal">G_PARAM_STATIC_BLURB</code></a>.
622
<div class="refsect2" lang="en">
623
<a name="id2942089"></a><h3>
624
<a name="G-PARAM-MASK:CAPS"></a>G_PARAM_MASK</h3>
625
<a class="indexterm" name="id2942102"></a><pre class="programlisting">#define G_PARAM_MASK (0x000000ff)
628
Mask containing the bits of <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>.flags which are reserved for GLib.
632
<div class="refsect2" lang="en">
633
<a name="id2942126"></a><h3>
634
<a name="G-PARAM-USER-SHIFT:CAPS"></a>G_PARAM_USER_SHIFT</h3>
635
<a class="indexterm" name="id2942140"></a><pre class="programlisting">#define G_PARAM_USER_SHIFT (8)
588
<a name="G-PARAM-READWRITE--CAPS"></a><h3>G_PARAM_READWRITE</h3>
589
<pre class="programlisting">#define G_PARAM_READWRITE (G_PARAM_READABLE | G_PARAM_WRITABLE)
592
<a class="link" href="gobject-GParamSpec.html#GParamFlags" title="enum GParamFlags"><span class="type">GParamFlags</span></a> value alias for <a class="link" href="gobject-GParamSpec.html#G-PARAM-READABLE--CAPS"><code class="literal">G_PARAM_READABLE</code></a> | <a class="link" href="gobject-GParamSpec.html#G-PARAM-WRITABLE--CAPS"><code class="literal">G_PARAM_WRITABLE</code></a>.</p>
597
<div class="refsect2" lang="en">
598
<a name="G-PARAM-STATIC-STRINGS--CAPS"></a><h3>G_PARAM_STATIC_STRINGS</h3>
599
<pre class="programlisting">#define G_PARAM_STATIC_STRINGS (G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB)
602
<a class="link" href="gobject-GParamSpec.html#GParamFlags" title="enum GParamFlags"><span class="type">GParamFlags</span></a> value alias for <a class="link" href="gobject-GParamSpec.html#G-PARAM-STATIC-NAME--CAPS"><code class="literal">G_PARAM_STATIC_NAME</code></a> | <a class="link" href="gobject-GParamSpec.html#G-PARAM-STATIC-NICK--CAPS"><code class="literal">G_PARAM_STATIC_NICK</code></a> | <a class="link" href="gobject-GParamSpec.html#G-PARAM-STATIC-BLURB--CAPS"><code class="literal">G_PARAM_STATIC_BLURB</code></a>.
610
<div class="refsect2" lang="en">
611
<a name="G-PARAM-MASK--CAPS"></a><h3>G_PARAM_MASK</h3>
612
<pre class="programlisting">#define G_PARAM_MASK (0x000000ff)
615
Mask containing the bits of <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>.flags which are reserved for GLib.</p>
620
<div class="refsect2" lang="en">
621
<a name="G-PARAM-USER-SHIFT--CAPS"></a><h3>G_PARAM_USER_SHIFT</h3>
622
<pre class="programlisting">#define G_PARAM_USER_SHIFT (8)
638
625
Minimum shift count to be used for user defined flags, to be stored in
639
<a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>.flags.
643
<div class="refsect2" lang="en">
644
<a name="id2942164"></a><h3>
645
<a name="g-param-spec-ref"></a>g_param_spec_ref ()</h3>
646
<a class="indexterm" name="id2942176"></a><pre class="programlisting"><a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a>* g_param_spec_ref (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec);</pre>
648
Increments the reference count of <em class="parameter"><code>pspec</code></em>.
650
<div class="variablelist"><table border="0">
651
<col align="left" valign="top">
654
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
655
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
659
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
660
<td>the <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a> that was passed into this function
669
<div class="refsect2" lang="en">
670
<a name="id2942256"></a><h3>
671
<a name="g-param-spec-unref"></a>g_param_spec_unref ()</h3>
672
<a class="indexterm" name="id2942269"></a><pre class="programlisting">void g_param_spec_unref (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec);</pre>
674
Decrements the reference count of a <em class="parameter"><code>pspec</code></em>.
676
<div class="variablelist"><table border="0">
677
<col align="left" valign="top">
679
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
680
<td>a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
688
<div class="refsect2" lang="en">
689
<a name="id2942329"></a><h3>
690
<a name="g-param-spec-sink"></a>g_param_spec_sink ()</h3>
691
<a class="indexterm" name="id2942343"></a><pre class="programlisting">void g_param_spec_sink (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec);</pre>
693
The initial reference count of a newly created <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a> is 1, even
694
though no one has explicitly called <a class="link" href="gobject-GParamSpec.html#g-param-spec-ref"><code class="function">g_param_spec_ref()</code></a> on it yet. So the
695
initial reference count is flagged as "floating", until someone calls
696
<code class="literal">g_param_spec_ref (pspec); g_param_spec_sink (pspec);</code>
697
in sequence on it, taking over the initial reference count (thus
698
ending up with a <em class="parameter"><code>pspec</code></em> that has a reference count of 1 still, but is
699
not flagged "floating" anymore).
701
<div class="variablelist"><table border="0">
702
<col align="left" valign="top">
704
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
705
<td>a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
713
<div class="refsect2" lang="en">
714
<a name="id2942433"></a><h3>
715
<a name="g-param-spec-ref-sink"></a>g_param_spec_ref_sink ()</h3>
716
<a class="indexterm" name="id2942449"></a><pre class="programlisting"><a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a>* g_param_spec_ref_sink (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec);</pre>
718
Convenience function to ref and sink a <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>.
720
<div class="variablelist"><table border="0">
721
<col align="left" valign="top">
724
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
725
<td>a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
729
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
730
<td>the <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a> that was passed into this function
735
<p class="since">Since 2.10
741
<div class="refsect2" lang="en">
742
<a name="id2942538"></a><h3>
743
<a name="g-param-value-set-default"></a>g_param_value_set_default ()</h3>
744
<a class="indexterm" name="id2942551"></a><pre class="programlisting">void g_param_value_set_default (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec,
745
<a class="link" href="gobject-Generic-values.html#GValue">GValue</a> *value);</pre>
747
Sets <em class="parameter"><code>value</code></em> to its default value as specified in <em class="parameter"><code>pspec</code></em>.
749
<div class="variablelist"><table border="0">
750
<col align="left" valign="top">
753
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
754
<td>a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
758
<td><p><span class="term"><em class="parameter"><code>value</code></em> :</span></p></td>
759
<td>a <a class="link" href="gobject-Generic-values.html#GValue"><span class="type">GValue</span></a> of correct type for <em class="parameter"><code>pspec</code></em>
768
<div class="refsect2" lang="en">
769
<a name="id2942653"></a><h3>
770
<a name="g-param-value-defaults"></a>g_param_value_defaults ()</h3>
771
<a class="indexterm" name="id2942666"></a><pre class="programlisting"><a
772
href="./../glib/glib/glib-Basic-Types.html#gboolean"
773
>gboolean</a> g_param_value_defaults (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec,
774
<a class="link" href="gobject-Generic-values.html#GValue">GValue</a> *value);</pre>
776
Checks whether <em class="parameter"><code>value</code></em> contains the default value as specified in <em class="parameter"><code>pspec</code></em>.
778
<div class="variablelist"><table border="0">
779
<col align="left" valign="top">
782
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
783
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
787
<td><p><span class="term"><em class="parameter"><code>value</code></em> :</span></p></td>
788
<td> a <a class="link" href="gobject-Generic-values.html#GValue"><span class="type">GValue</span></a> of correct type for <em class="parameter"><code>pspec</code></em>
792
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
793
<td>whether <em class="parameter"><code>value</code></em> contains the canonical default for this <em class="parameter"><code>pspec</code></em>
802
<div class="refsect2" lang="en">
803
<a name="id2942791"></a><h3>
804
<a name="g-param-value-validate"></a>g_param_value_validate ()</h3>
805
<a class="indexterm" name="id2942805"></a><pre class="programlisting"><a
806
href="./../glib/glib/glib-Basic-Types.html#gboolean"
807
>gboolean</a> g_param_value_validate (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec,
808
<a class="link" href="gobject-Generic-values.html#GValue">GValue</a> *value);</pre>
626
<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>.flags.</p>
631
<div class="refsect2" lang="en">
632
<a name="g-param-spec-ref"></a><h3>g_param_spec_ref ()</h3>
633
<pre class="programlisting"><a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a>* g_param_spec_ref (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec);</pre>
635
Increments the reference count of <em class="parameter"><code>pspec</code></em>.</p>
638
<div class="variablelist"><table border="0">
639
<col align="left" valign="top">
642
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
643
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
647
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
648
<td> the <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a> that was passed into this function
655
<div class="refsect2" lang="en">
656
<a name="g-param-spec-unref"></a><h3>g_param_spec_unref ()</h3>
657
<pre class="programlisting">void g_param_spec_unref (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec);</pre>
659
Decrements the reference count of a <em class="parameter"><code>pspec</code></em>.</p>
662
<div class="variablelist"><table border="0">
663
<col align="left" valign="top">
665
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
666
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
672
<div class="refsect2" lang="en">
673
<a name="g-param-spec-sink"></a><h3>g_param_spec_sink ()</h3>
674
<pre class="programlisting">void g_param_spec_sink (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec);</pre>
676
The initial reference count of a newly created <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a> is 1,
677
even though no one has explicitly called <a class="link" href="gobject-GParamSpec.html#g-param-spec-ref" title="g_param_spec_ref ()"><code class="function">g_param_spec_ref()</code></a> on it
678
yet. So the initial reference count is flagged as "floating", until
679
someone calls <code class="literal">g_param_spec_ref (pspec); g_param_spec_sink
680
(pspec);</code> in sequence on it, taking over the initial
681
reference count (thus ending up with a <em class="parameter"><code>pspec</code></em> that has a reference
682
count of 1 still, but is not flagged "floating" anymore).</p>
685
<div class="variablelist"><table border="0">
686
<col align="left" valign="top">
688
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
689
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
695
<div class="refsect2" lang="en">
696
<a name="g-param-spec-ref-sink"></a><h3>g_param_spec_ref_sink ()</h3>
697
<pre class="programlisting"><a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a>* g_param_spec_ref_sink (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec);</pre>
699
Convenience function to ref and sink a <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>.</p>
702
<div class="variablelist"><table border="0">
703
<col align="left" valign="top">
706
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
707
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
711
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
712
<td> the <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a> that was passed into this function
717
<p class="since">Since 2.10</p>
720
<div class="refsect2" lang="en">
721
<a name="g-param-value-set-default"></a><h3>g_param_value_set_default ()</h3>
722
<pre class="programlisting">void g_param_value_set_default (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec,
723
<a class="link" href="gobject-Generic-values.html#GValue" title="GValue">GValue</a> *value);</pre>
725
Sets <em class="parameter"><code>value</code></em> to its default value as specified in <em class="parameter"><code>pspec</code></em>.</p>
728
<div class="variablelist"><table border="0">
729
<col align="left" valign="top">
732
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
733
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
737
<td><p><span class="term"><em class="parameter"><code>value</code></em> :</span></p></td>
738
<td> a <a class="link" href="gobject-Generic-values.html#GValue" title="GValue"><span class="type">GValue</span></a> of correct type for <em class="parameter"><code>pspec</code></em>
745
<div class="refsect2" lang="en">
746
<a name="g-param-value-defaults"></a><h3>g_param_value_defaults ()</h3>
747
<pre class="programlisting"><a
748
href="./../glib/glib/glib-Basic-Types.html#gboolean"
749
>gboolean</a> g_param_value_defaults (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec,
750
<a class="link" href="gobject-Generic-values.html#GValue" title="GValue">GValue</a> *value);</pre>
752
Checks whether <em class="parameter"><code>value</code></em> contains the default value as specified in <em class="parameter"><code>pspec</code></em>.</p>
755
<div class="variablelist"><table border="0">
756
<col align="left" valign="top">
759
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
760
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
764
<td><p><span class="term"><em class="parameter"><code>value</code></em> :</span></p></td>
765
<td> a <a class="link" href="gobject-Generic-values.html#GValue" title="GValue"><span class="type">GValue</span></a> of correct type for <em class="parameter"><code>pspec</code></em>
769
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
770
<td> whether <em class="parameter"><code>value</code></em> contains the canonical default for this <em class="parameter"><code>pspec</code></em>
777
<div class="refsect2" lang="en">
778
<a name="g-param-value-validate"></a><h3>g_param_value_validate ()</h3>
779
<pre class="programlisting"><a
780
href="./../glib/glib/glib-Basic-Types.html#gboolean"
781
>gboolean</a> g_param_value_validate (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec,
782
<a class="link" href="gobject-Generic-values.html#GValue" title="GValue">GValue</a> *value);</pre>
810
784
Ensures that the contents of <em class="parameter"><code>value</code></em> comply with the specifications
811
set out by <em class="parameter"><code>pspec</code></em>. For example, a <a class="link" href="gobject-Standard-Parameter-and-Value-Types.html#GParamSpecInt"><span class="type">GParamSpecInt</span></a> might require
785
set out by <em class="parameter"><code>pspec</code></em>. For example, a <a class="link" href="gobject-Standard-Parameter-and-Value-Types.html#GParamSpecInt" title="GParamSpecInt"><span class="type">GParamSpecInt</span></a> might require
812
786
that integers stored in <em class="parameter"><code>value</code></em> may not be smaller than -42 and not be
813
787
greater than +42. If <em class="parameter"><code>value</code></em> contains an integer outside of this range,
814
788
it is modified accordingly, so the resulting value will fit into the
789
range -42 .. +42.</p>
817
792
<div class="variablelist"><table border="0">
818
793
<col align="left" valign="top">
821
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
822
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
826
<td><p><span class="term"><em class="parameter"><code>value</code></em> :</span></p></td>
827
<td> a <a class="link" href="gobject-Generic-values.html#GValue"><span class="type">GValue</span></a> of correct type for <em class="parameter"><code>pspec</code></em>
831
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
832
<td>whether modifying <em class="parameter"><code>value</code></em> was necessary to ensure validity
796
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
797
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
801
<td><p><span class="term"><em class="parameter"><code>value</code></em> :</span></p></td>
802
<td> a <a class="link" href="gobject-Generic-values.html#GValue" title="GValue"><span class="type">GValue</span></a> of correct type for <em class="parameter"><code>pspec</code></em>
806
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
807
<td> whether modifying <em class="parameter"><code>value</code></em> was necessary to ensure validity
841
814
<div class="refsect2" lang="en">
842
<a name="id2942949"></a><h3>
843
<a name="g-param-value-convert"></a>g_param_value_convert ()</h3>
844
<a class="indexterm" name="id2942962"></a><pre class="programlisting"><a
815
<a name="g-param-value-convert"></a><h3>g_param_value_convert ()</h3>
816
<pre class="programlisting"><a
845
817
href="./../glib/glib/glib-Basic-Types.html#gboolean"
846
>gboolean</a> g_param_value_convert (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec,
847
const <a class="link" href="gobject-Generic-values.html#GValue">GValue</a> *src_value,
848
<a class="link" href="gobject-Generic-values.html#GValue">GValue</a> *dest_value,
818
>gboolean</a> g_param_value_convert (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec,
819
const <a class="link" href="gobject-Generic-values.html#GValue" title="GValue">GValue</a> *src_value,
820
<a class="link" href="gobject-Generic-values.html#GValue" title="GValue">GValue</a> *dest_value,
850
822
href="./../glib/glib/glib-Basic-Types.html#gboolean"
851
823
>gboolean</a> strict_validation);</pre>
853
Transforms <em class="parameter"><code>src_value</code></em> into <em class="parameter"><code>dest_value</code></em> if possible, and then validates
854
<em class="parameter"><code>dest_value</code></em>, in order for it to conform to <em class="parameter"><code>pspec</code></em>.
855
If <em class="parameter"><code>strict_validation</code></em> is <a
856
href="./../glib/glib/glib-Standard-Macros.html#TRUE:CAPS"
857
><code class="literal">TRUE</code></a> this function will only succeed if
858
the transformed <em class="parameter"><code>dest_value</code></em> complied to <em class="parameter"><code>pspec</code></em> without modifications.
860
See also <a class="link" href="gobject-Generic-values.html#g-value-type-transformable"><code class="function">g_value_type_transformable()</code></a>, <a class="link" href="gobject-Generic-values.html#g-value-transform"><code class="function">g_value_transform()</code></a> and
861
<a class="link" href="gobject-GParamSpec.html#g-param-value-validate"><code class="function">g_param_value_validate()</code></a>.
825
Transforms <em class="parameter"><code>src_value</code></em> into <em class="parameter"><code>dest_value</code></em> if possible, and then
826
validates <em class="parameter"><code>dest_value</code></em>, in order for it to conform to <em class="parameter"><code>pspec</code></em>. If
827
<em class="parameter"><code>strict_validation</code></em> is <a
828
href="./../glib/glib/glib-Standard-Macros.html#TRUE--CAPS"
829
><code class="literal">TRUE</code></a> this function will only succeed if the
830
transformed <em class="parameter"><code>dest_value</code></em> complied to <em class="parameter"><code>pspec</code></em> without modifications.
833
See also <a class="link" href="gobject-Generic-values.html#g-value-type-transformable" title="g_value_type_transformable ()"><code class="function">g_value_type_transformable()</code></a>, <a class="link" href="gobject-Generic-values.html#g-value-transform" title="g_value_transform ()"><code class="function">g_value_transform()</code></a> and
834
<a class="link" href="gobject-GParamSpec.html#g-param-value-validate" title="g_param_value_validate ()"><code class="function">g_param_value_validate()</code></a>.</p>
863
837
<div class="variablelist"><table border="0">
864
838
<col align="left" valign="top">
867
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
868
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
872
<td><p><span class="term"><em class="parameter"><code>src_value</code></em> :</span></p></td>
873
<td> souce <a class="link" href="gobject-Generic-values.html#GValue"><span class="type">GValue</span></a>
877
<td><p><span class="term"><em class="parameter"><code>dest_value</code></em> :</span></p></td>
878
<td> destination <a class="link" href="gobject-Generic-values.html#GValue"><span class="type">GValue</span></a> of correct type for <em class="parameter"><code>pspec</code></em>
882
<td><p><span class="term"><em class="parameter"><code>strict_validation</code></em> :</span></p></td>
885
href="./../glib/glib/glib-Standard-Macros.html#TRUE:CAPS"
886
><code class="literal">TRUE</code></a> requires <em class="parameter"><code>dest_value</code></em> to conform to <em class="parameter"><code>pspec</code></em> without modifications
890
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
892
href="./../glib/glib/glib-Standard-Macros.html#TRUE:CAPS"
841
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
842
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
846
<td><p><span class="term"><em class="parameter"><code>src_value</code></em> :</span></p></td>
847
<td> souce <a class="link" href="gobject-Generic-values.html#GValue" title="GValue"><span class="type">GValue</span></a>
851
<td><p><span class="term"><em class="parameter"><code>dest_value</code></em> :</span></p></td>
852
<td> destination <a class="link" href="gobject-Generic-values.html#GValue" title="GValue"><span class="type">GValue</span></a> of correct type for <em class="parameter"><code>pspec</code></em>
856
<td><p><span class="term"><em class="parameter"><code>strict_validation</code></em> :</span></p></td>
858
href="./../glib/glib/glib-Standard-Macros.html#TRUE--CAPS"
859
><code class="literal">TRUE</code></a> requires <em class="parameter"><code>dest_value</code></em> to conform to <em class="parameter"><code>pspec</code></em>
860
without modifications
864
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
866
href="./../glib/glib/glib-Standard-Macros.html#TRUE--CAPS"
893
867
><code class="literal">TRUE</code></a> if transformation and validation were successful,
895
href="./../glib/glib/glib-Standard-Macros.html#FALSE:CAPS"
869
href="./../glib/glib/glib-Standard-Macros.html#FALSE--CAPS"
896
870
><code class="literal">FALSE</code></a> otherwise and <em class="parameter"><code>dest_value</code></em> is left untouched.
905
877
<div class="refsect2" lang="en">
906
<a name="id2943251"></a><h3>
907
<a name="g-param-values-cmp"></a>g_param_values_cmp ()</h3>
908
<a class="indexterm" name="id2943264"></a><pre class="programlisting"><a
878
<a name="g-param-values-cmp"></a><h3>g_param_values_cmp ()</h3>
879
<pre class="programlisting"><a
909
880
href="./../glib/glib/glib-Basic-Types.html#gint"
910
>gint</a> g_param_values_cmp (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec,
911
const <a class="link" href="gobject-Generic-values.html#GValue">GValue</a> *value1,
912
const <a class="link" href="gobject-Generic-values.html#GValue">GValue</a> *value2);</pre>
881
>gint</a> g_param_values_cmp (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec,
882
const <a class="link" href="gobject-Generic-values.html#GValue" title="GValue">GValue</a> *value1,
883
const <a class="link" href="gobject-Generic-values.html#GValue" title="GValue">GValue</a> *value2);</pre>
914
885
Compares <em class="parameter"><code>value1</code></em> with <em class="parameter"><code>value2</code></em> according to <em class="parameter"><code>pspec</code></em>, and return -1, 0 or +1,
915
if <em class="parameter"><code>value1</code></em> is found to be less than, equal to or greater than <em class="parameter"><code>value2</code></em>,
918
<div class="variablelist"><table border="0">
919
<col align="left" valign="top">
922
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
923
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
927
<td><p><span class="term"><em class="parameter"><code>value1</code></em> :</span></p></td>
928
<td> a <a class="link" href="gobject-Generic-values.html#GValue"><span class="type">GValue</span></a> of correct type for <em class="parameter"><code>pspec</code></em>
932
<td><p><span class="term"><em class="parameter"><code>value2</code></em> :</span></p></td>
933
<td> a <a class="link" href="gobject-Generic-values.html#GValue"><span class="type">GValue</span></a> of correct type for <em class="parameter"><code>pspec</code></em>
937
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
938
<td>-1, 0 or +1, for a less than, equal to or greater than result
947
<div class="refsect2" lang="en">
948
<a name="id2943432"></a><h3>
949
<a name="g-param-spec-get-name"></a>g_param_spec_get_name ()</h3>
950
<a class="indexterm" name="id2943445"></a><pre class="programlisting">const <a
951
href="./../glib/glib/glib-Basic-Types.html#gchar"
952
>gchar</a>* g_param_spec_get_name (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec);</pre>
954
Returns the name of a <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>.
956
<div class="variablelist"><table border="0">
957
<col align="left" valign="top">
960
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
961
<td>a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
965
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
966
<td>the name of <em class="parameter"><code>pspec</code></em>.
975
<div class="refsect2" lang="en">
976
<a name="id2943526"></a><h3>
977
<a name="g-param-spec-get-nick"></a>g_param_spec_get_nick ()</h3>
978
<a class="indexterm" name="id2943539"></a><pre class="programlisting">const <a
979
href="./../glib/glib/glib-Basic-Types.html#gchar"
980
>gchar</a>* g_param_spec_get_nick (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec);</pre>
982
Returns the nickname of a <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>.
984
<div class="variablelist"><table border="0">
985
<col align="left" valign="top">
988
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
989
<td>a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
993
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
994
<td>the nickname of <em class="parameter"><code>pspec</code></em>.
1003
<div class="refsect2" lang="en">
1004
<a name="id2943619"></a><h3>
1005
<a name="g-param-spec-get-blurb"></a>g_param_spec_get_blurb ()</h3>
1006
<a class="indexterm" name="id2943632"></a><pre class="programlisting">const <a
1007
href="./../glib/glib/glib-Basic-Types.html#gchar"
1008
>gchar</a>* g_param_spec_get_blurb (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec);</pre>
1010
Returns the short description of a <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>.
1012
<div class="variablelist"><table border="0">
1013
<col align="left" valign="top">
1016
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
1017
<td>a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
1021
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1022
<td>the short description of <em class="parameter"><code>pspec</code></em>.
1031
<div class="refsect2" lang="en">
1032
<a name="id2943713"></a><h3>
1033
<a name="g-param-spec-get-qdata"></a>g_param_spec_get_qdata ()</h3>
1034
<a class="indexterm" name="id2943726"></a><pre class="programlisting"><a
886
if <em class="parameter"><code>value1</code></em> is found to be less than, equal to or greater than <em class="parameter"><code>value2</code></em>,
890
<div class="variablelist"><table border="0">
891
<col align="left" valign="top">
894
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
895
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
899
<td><p><span class="term"><em class="parameter"><code>value1</code></em> :</span></p></td>
900
<td> a <a class="link" href="gobject-Generic-values.html#GValue" title="GValue"><span class="type">GValue</span></a> of correct type for <em class="parameter"><code>pspec</code></em>
904
<td><p><span class="term"><em class="parameter"><code>value2</code></em> :</span></p></td>
905
<td> a <a class="link" href="gobject-Generic-values.html#GValue" title="GValue"><span class="type">GValue</span></a> of correct type for <em class="parameter"><code>pspec</code></em>
909
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
910
<td> -1, 0 or +1, for a less than, equal to or greater than result
917
<div class="refsect2" lang="en">
918
<a name="g-param-spec-get-name"></a><h3>g_param_spec_get_name ()</h3>
919
<pre class="programlisting">const <a
920
href="./../glib/glib/glib-Basic-Types.html#gchar"
921
>gchar</a>* g_param_spec_get_name (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec);</pre>
923
Get the name of a <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>.</p>
926
<div class="variablelist"><table border="0">
927
<col align="left" valign="top">
930
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
931
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
935
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
936
<td> the name of <em class="parameter"><code>pspec</code></em>.
943
<div class="refsect2" lang="en">
944
<a name="g-param-spec-get-nick"></a><h3>g_param_spec_get_nick ()</h3>
945
<pre class="programlisting">const <a
946
href="./../glib/glib/glib-Basic-Types.html#gchar"
947
>gchar</a>* g_param_spec_get_nick (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec);</pre>
949
Get the nickname of a <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>.</p>
952
<div class="variablelist"><table border="0">
953
<col align="left" valign="top">
956
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
957
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
961
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
962
<td> the nickname of <em class="parameter"><code>pspec</code></em>.
969
<div class="refsect2" lang="en">
970
<a name="g-param-spec-get-blurb"></a><h3>g_param_spec_get_blurb ()</h3>
971
<pre class="programlisting">const <a
972
href="./../glib/glib/glib-Basic-Types.html#gchar"
973
>gchar</a>* g_param_spec_get_blurb (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec);</pre>
975
Get the short description of a <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>.</p>
978
<div class="variablelist"><table border="0">
979
<col align="left" valign="top">
982
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
983
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
987
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
988
<td> the short description of <em class="parameter"><code>pspec</code></em>.
995
<div class="refsect2" lang="en">
996
<a name="g-param-spec-get-qdata"></a><h3>g_param_spec_get_qdata ()</h3>
997
<pre class="programlisting"><a
1035
998
href="./../glib/glib/glib-Basic-Types.html#gpointer"
1036
>gpointer</a> g_param_spec_get_qdata (<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec,
999
>gpointer</a> g_param_spec_get_qdata (<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec,
1038
1001
href="./../glib/glib/glib-Quarks.html#GQuark"
1039
1002
>GQuark</a> quark);</pre>
1041
Gets back user data pointers stored via <a class="link" href="gobject-GParamSpec.html#g-param-spec-set-qdata"><code class="function">g_param_spec_set_qdata()</code></a>.
1004
Gets back user data pointers stored via <a class="link" href="gobject-GParamSpec.html#g-param-spec-set-qdata" title="g_param_spec_set_qdata ()"><code class="function">g_param_spec_set_qdata()</code></a>.</p>
1043
1007
<div class="variablelist"><table border="0">
1044
1008
<col align="left" valign="top">
1047
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
1048
<td>a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
1011
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
1012
<td> a valid <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
1052
<td><p><span class="term"><em class="parameter"><code>quark</code></em> :</span></p></td>
1016
<td><p><span class="term"><em class="parameter"><code>quark</code></em> :</span></p></td>
1054
1018
href="./../glib/glib/glib-Quarks.html#GQuark"
1055
1019
><span class="type">GQuark</span></a>, naming the user data pointer
1059
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1060
<td>the user data pointer set, or <a
1061
href="./../glib/glib/glib-Standard-Macros.html#NULL:CAPS"
1023
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1024
<td> the user data pointer set, or <a
1025
href="./../glib/glib/glib-Standard-Macros.html#NULL--CAPS"
1062
1026
><code class="literal">NULL</code></a>
1267
1218
href="./../glib/glib/glib-Basic-Types.html#gchar"
1268
1219
>gchar</a> *blurb,
1269
<a class="link" href="gobject-GParamSpec.html#GParamFlags">GParamFlags</a> flags);</pre>
1220
<a class="link" href="gobject-GParamSpec.html#GParamFlags" title="enum GParamFlags">GParamFlags</a> flags);</pre>
1271
Creates a new <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a> instance.
1222
Creates a new <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a> instance.
1274
1225
A property name consists of segments consisting of ASCII letters and
1275
1226
digits, separated by either the '-' or '_' character. The first
1276
1227
character of a property name must be a letter. Names which violate these
1277
rules lead to undefined behaviour.
1280
When creating and looking up a <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>, either separator can be used,
1281
but they cannot be mixed. Using '-' is considerably more efficient and in
1282
fact required when using property names as detail strings for signals.
1228
rules lead to undefined behaviour.
1231
When creating and looking up a <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>, either separator can be
1232
used, but they cannot be mixed. Using '-' is considerably more
1233
efficient and in fact required when using property names as detail
1234
strings for signals.
1237
Beyond the name, <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>s have two more descriptive
1238
strings associated with them, the <em class="parameter"><code>nick</code></em>, which should be suitable
1239
for use as a label for the property in a property editor, and the
1240
<em class="parameter"><code>blurb</code></em>, which should be a somewhat longer description, suitable for
1241
e.g. a tooltip. The <em class="parameter"><code>nick</code></em> and <em class="parameter"><code>blurb</code></em> should ideally be localized.</p>
1284
1244
<div class="variablelist"><table border="0">
1285
1245
<col align="left" valign="top">
1288
<td><p><span class="term"><em class="parameter"><code>param_type</code></em> :</span></p></td>
1289
<td>the <a class="link" href="gobject-Type-Information.html#GType"><span class="type">GType</span></a> for the property; must be derived from <a class="link" href="gobject-Type-Information.html#G-TYPE-PARAM:CAPS"><span class="type">G_TYPE_PARAM</span></a>
1293
<td><p><span class="term"><em class="parameter"><code>name</code></em> :</span></p></td>
1294
<td>the canonical name of the property
1298
<td><p><span class="term"><em class="parameter"><code>nick</code></em> :</span></p></td>
1299
<td>the nickname of the property
1303
<td><p><span class="term"><em class="parameter"><code>blurb</code></em> :</span></p></td>
1304
<td>a short description of the property
1308
<td><p><span class="term"><em class="parameter"><code>flags</code></em> :</span></p></td>
1309
<td>a combination of <a class="link" href="gobject-GParamSpec.html#GParamFlags"><span class="type">GParamFlags</span></a>
1313
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1314
<td>a newly allocated <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a> instance
1248
<td><p><span class="term"><em class="parameter"><code>param_type</code></em> :</span></p></td>
1249
<td> the <a class="link" href="gobject-Type-Information.html#GType" title="GType"><span class="type">GType</span></a> for the property; must be derived from <a class="link" href="gobject-Type-Information.html#G-TYPE-PARAM--CAPS" title="G_TYPE_PARAM"><span class="type">G_TYPE_PARAM</span></a>
1253
<td><p><span class="term"><em class="parameter"><code>name</code></em> :</span></p></td>
1254
<td> the canonical name of the property
1258
<td><p><span class="term"><em class="parameter"><code>nick</code></em> :</span></p></td>
1259
<td> the nickname of the property
1263
<td><p><span class="term"><em class="parameter"><code>blurb</code></em> :</span></p></td>
1264
<td> a short description of the property
1268
<td><p><span class="term"><em class="parameter"><code>flags</code></em> :</span></p></td>
1269
<td> a combination of <a class="link" href="gobject-GParamSpec.html#GParamFlags" title="enum GParamFlags"><span class="type">GParamFlags</span></a>
1273
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1274
<td> a newly allocated <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a> instance
1357
1315
<td><p><span class="term"><a
1358
1316
href="./../glib/glib/glib-Basic-Types.html#guint16"
1359
>guint16</a> <em class="structfield"><code>instance_size</code></em>;</span></p></td>
1360
<td>Size of the instance (object) structure.
1317
>guint16</a> <em class="structfield"><code>instance_size</code></em>;</span></p></td>
1318
<td> Size of the instance (object) structure.
1364
1322
<td><p><span class="term"><a
1365
1323
href="./../glib/glib/glib-Basic-Types.html#guint16"
1366
>guint16</a> <em class="structfield"><code>n_preallocs</code></em>;</span></p></td>
1367
<td>Prior to GLib 2.10, it specified the number of pre-allocated (cached) instances to reserve memory for (0 indicates no caching). Since GLib 2.10, it is ignored, since instances are allocated with the <a
1324
>guint16</a> <em class="structfield"><code>n_preallocs</code></em>;</span></p></td>
1325
<td> Prior to GLib 2.10, it specified the number of pre-allocated (cached) instances to reserve memory for (0 indicates no caching). Since GLib 2.10, it is ignored, since instances are allocated with the <a
1368
1326
href="./../glib/glib/glib-Memory-Slices.html"
1369
1327
>slice allocator</a> now.
1373
<td><p><span class="term"><em class="structfield"><code>instance_init</code></em> ()</span></p></td>
1374
<td>Location of the instance initialization function (optional).
1378
<td><p><span class="term"><a class="link" href="gobject-Type-Information.html#GType">GType</a> <em class="structfield"><code>value_type</code></em>;</span></p></td>
1379
<td>The <a class="link" href="gobject-Type-Information.html#GType"><span class="type">GType</span></a> of values conforming to this <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>
1383
<td><p><span class="term"><em class="structfield"><code>finalize</code></em> ()</span></p></td>
1384
<td>The instance finalization function (optional).
1388
<td><p><span class="term"><em class="structfield"><code>value_set_default</code></em> ()</span></p></td>
1389
<td>Resets a <em class="parameter"><code>value</code></em> to the default value for <em class="parameter"><code>pspec</code></em>
1390
(recommended, the default is <a class="link" href="gobject-Generic-values.html#g-value-reset"><code class="function">g_value_reset()</code></a>), see
1391
<a class="link" href="gobject-GParamSpec.html#g-param-value-set-default"><code class="function">g_param_value_set_default()</code></a>.
1395
<td><p><span class="term"><em class="structfield"><code>value_validate</code></em> ()</span></p></td>
1396
<td>Ensures that the contents of <em class="parameter"><code>value</code></em> comply with the
1397
specifications set out by <em class="parameter"><code>pspec</code></em> (optional), see
1398
<code class="function">g_param_value_set_validate()</code>.
1402
<td><p><span class="term"><em class="structfield"><code>values_cmp</code></em> ()</span></p></td>
1403
<td>Compares <em class="parameter"><code>value1</code></em> with <em class="parameter"><code>value2</code></em> according to <em class="parameter"><code>pspec</code></em>
1404
(recommended, the default is <code class="function">memcmp()</code>), see <a class="link" href="gobject-GParamSpec.html#g-param-values-cmp"><code class="function">g_param_values_cmp()</code></a>.
1331
<td><p><span class="term"><em class="structfield"><code>instance_init</code></em> ()</span></p></td>
1332
<td> Location of the instance initialization function (optional).
1336
<td><p><span class="term"><a class="link" href="gobject-Type-Information.html#GType" title="GType">GType</a> <em class="structfield"><code>value_type</code></em>;</span></p></td>
1337
<td> The <a class="link" href="gobject-Type-Information.html#GType" title="GType"><span class="type">GType</span></a> of values conforming to this <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>
1341
<td><p><span class="term"><em class="structfield"><code>finalize</code></em> ()</span></p></td>
1342
<td> The instance finalization function (optional).
1346
<td><p><span class="term"><em class="structfield"><code>value_set_default</code></em> ()</span></p></td>
1347
<td> Resets a <em class="parameter"><code>value</code></em> to the default value for <em class="parameter"><code>pspec</code></em>
1348
(recommended, the default is <a class="link" href="gobject-Generic-values.html#g-value-reset" title="g_value_reset ()"><code class="function">g_value_reset()</code></a>), see
1349
<a class="link" href="gobject-GParamSpec.html#g-param-value-set-default" title="g_param_value_set_default ()"><code class="function">g_param_value_set_default()</code></a>.
1353
<td><p><span class="term"><em class="structfield"><code>value_validate</code></em> ()</span></p></td>
1354
<td> Ensures that the contents of <em class="parameter"><code>value</code></em> comply with the
1355
specifications set out by <em class="parameter"><code>pspec</code></em> (optional), see
1356
<code class="function">g_param_value_set_validate()</code>.
1360
<td><p><span class="term"><em class="structfield"><code>values_cmp</code></em> ()</span></p></td>
1361
<td> Compares <em class="parameter"><code>value1</code></em> with <em class="parameter"><code>value2</code></em> according to <em class="parameter"><code>pspec</code></em>
1362
(recommended, the default is <code class="function">memcmp()</code>), see <a class="link" href="gobject-GParamSpec.html#g-param-values-cmp" title="g_param_values_cmp ()"><code class="function">g_param_values_cmp()</code></a>.
1449
1404
<div class="refsect2" lang="en">
1450
<a name="id2945213"></a><h3>
1451
<a name="GParamSpecPool"></a>GParamSpecPool</h3>
1452
<a class="indexterm" name="id2945226"></a><pre class="programlisting">typedef struct _GParamSpecPool GParamSpecPool;</pre>
1405
<a name="GParamSpecPool"></a><h3>GParamSpecPool</h3>
1406
<pre class="programlisting">typedef struct _GParamSpecPool GParamSpecPool;</pre>
1454
A <a class="link" href="gobject-GParamSpec.html#GParamSpecPool"><span class="type">GParamSpecPool</span></a> maintains a collection of <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>s which can be
1408
A <a class="link" href="gobject-GParamSpec.html#GParamSpecPool" title="GParamSpecPool"><span class="type">GParamSpecPool</span></a> maintains a collection of <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>s which can be
1455
1409
quickly accessed by owner and name. The implementation of the <a class="link" href="gobject-The-Base-Object-Type.html#GObject"><span class="type">GObject</span></a> property
1456
1410
system uses such a pool to store the <span class="type">GParamSpecs</span> of the properties all object
1461
1416
<div class="refsect2" lang="en">
1462
<a name="id2945280"></a><h3>
1463
<a name="g-param-spec-pool-new"></a>g_param_spec_pool_new ()</h3>
1464
<a class="indexterm" name="id2945293"></a><pre class="programlisting"><a class="link" href="gobject-GParamSpec.html#GParamSpecPool">GParamSpecPool</a>* g_param_spec_pool_new (<a
1417
<a name="g-param-spec-pool-new"></a><h3>g_param_spec_pool_new ()</h3>
1418
<pre class="programlisting"><a class="link" href="gobject-GParamSpec.html#GParamSpecPool" title="GParamSpecPool">GParamSpecPool</a>* g_param_spec_pool_new (<a
1465
1419
href="./../glib/glib/glib-Basic-Types.html#gboolean"
1466
1420
>gboolean</a> type_prefixing);</pre>
1468
Creates a new <a class="link" href="gobject-GParamSpec.html#GParamSpecPool"><span class="type">GParamSpecPool</span></a>.
1422
Creates a new <a class="link" href="gobject-GParamSpec.html#GParamSpecPool" title="GParamSpecPool"><span class="type">GParamSpecPool</span></a>.
1471
1425
If <em class="parameter"><code>type_prefixing</code></em> is <a
1472
href="./../glib/glib/glib-Standard-Macros.html#TRUE:CAPS"
1426
href="./../glib/glib/glib-Standard-Macros.html#TRUE--CAPS"
1473
1427
><code class="literal">TRUE</code></a>, lookups in the newly created pool will
1474
allow to specify the owner as a colon-separated prefix of the property name,
1475
like "GtkContainer:border-width". This feature is deprecated, so you should
1476
always set <em class="parameter"><code>type_prefixing</code></em> to <a
1477
href="./../glib/glib/glib-Standard-Macros.html#FALSE:CAPS"
1478
><code class="literal">FALSE</code></a>.
1480
<div class="variablelist"><table border="0">
1481
<col align="left" valign="top">
1484
<td><p><span class="term"><em class="parameter"><code>type_prefixing</code></em> :</span></p></td>
1485
<td>Whether the pool will support type-prefixed property names.
1489
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1490
<td>a newly allocated <a class="link" href="gobject-GParamSpec.html#GParamSpecPool"><span class="type">GParamSpecPool</span></a>.
1499
<div class="refsect2" lang="en">
1500
<a name="id2945408"></a><h3>
1501
<a name="g-param-spec-pool-insert"></a>g_param_spec_pool_insert ()</h3>
1502
<a class="indexterm" name="id2945421"></a><pre class="programlisting">void g_param_spec_pool_insert (<a class="link" href="gobject-GParamSpec.html#GParamSpecPool">GParamSpecPool</a> *pool,
1503
<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec,
1504
<a class="link" href="gobject-Type-Information.html#GType">GType</a> owner_type);</pre>
1506
Inserts a <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a> in the pool.
1508
<div class="variablelist"><table border="0">
1509
<col align="left" valign="top">
1512
<td><p><span class="term"><em class="parameter"><code>pool</code></em> :</span></p></td>
1513
<td>a <a class="link" href="gobject-GParamSpec.html#GParamSpecPool"><span class="type">GParamSpecPool</span></a>.
1517
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
1518
<td>the <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a> to insert
1522
<td><p><span class="term"><em class="parameter"><code>owner_type</code></em> :</span></p></td>
1523
<td>a <a class="link" href="gobject-Type-Information.html#GType"><span class="type">GType</span></a> identifying the owner of <em class="parameter"><code>pspec</code></em>
1532
<div class="refsect2" lang="en">
1533
<a name="id2945549"></a><h3>
1534
<a name="g-param-spec-pool-remove"></a>g_param_spec_pool_remove ()</h3>
1535
<a class="indexterm" name="id2945563"></a><pre class="programlisting">void g_param_spec_pool_remove (<a class="link" href="gobject-GParamSpec.html#GParamSpecPool">GParamSpecPool</a> *pool,
1536
<a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a> *pspec);</pre>
1538
Removes a <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a> from the pool.
1540
<div class="variablelist"><table border="0">
1541
<col align="left" valign="top">
1544
<td><p><span class="term"><em class="parameter"><code>pool</code></em> :</span></p></td>
1545
<td>a <a class="link" href="gobject-GParamSpec.html#GParamSpecPool"><span class="type">GParamSpecPool</span></a>
1549
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
1550
<td>the <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a> to remove
1559
<div class="refsect2" lang="en">
1560
<a name="id2945656"></a><h3>
1561
<a name="g-param-spec-pool-lookup"></a>g_param_spec_pool_lookup ()</h3>
1562
<a class="indexterm" name="id2945669"></a><pre class="programlisting"><a class="link" href="gobject-GParamSpec.html#GParamSpec">GParamSpec</a>* g_param_spec_pool_lookup (<a class="link" href="gobject-GParamSpec.html#GParamSpecPool">GParamSpecPool</a> *pool,
1428
allow to specify the owner as a colon-separated prefix of the
1429
property name, like "GtkContainer:border-width". This feature is
1430
deprecated, so you should always set <em class="parameter"><code>type_prefixing</code></em> to <a
1431
href="./../glib/glib/glib-Standard-Macros.html#FALSE--CAPS"
1432
><code class="literal">FALSE</code></a>.</p>
1435
<div class="variablelist"><table border="0">
1436
<col align="left" valign="top">
1439
<td><p><span class="term"><em class="parameter"><code>type_prefixing</code></em> :</span></p></td>
1440
<td> Whether the pool will support type-prefixed property names.
1444
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1445
<td> a newly allocated <a class="link" href="gobject-GParamSpec.html#GParamSpecPool" title="GParamSpecPool"><span class="type">GParamSpecPool</span></a>.
1452
<div class="refsect2" lang="en">
1453
<a name="g-param-spec-pool-insert"></a><h3>g_param_spec_pool_insert ()</h3>
1454
<pre class="programlisting">void g_param_spec_pool_insert (<a class="link" href="gobject-GParamSpec.html#GParamSpecPool" title="GParamSpecPool">GParamSpecPool</a> *pool,
1455
<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec,
1456
<a class="link" href="gobject-Type-Information.html#GType" title="GType">GType</a> owner_type);</pre>
1458
Inserts a <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a> in the pool.</p>
1461
<div class="variablelist"><table border="0">
1462
<col align="left" valign="top">
1465
<td><p><span class="term"><em class="parameter"><code>pool</code></em> :</span></p></td>
1466
<td> a <a class="link" href="gobject-GParamSpec.html#GParamSpecPool" title="GParamSpecPool"><span class="type">GParamSpecPool</span></a>.
1470
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
1471
<td> the <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a> to insert
1475
<td><p><span class="term"><em class="parameter"><code>owner_type</code></em> :</span></p></td>
1476
<td> a <a class="link" href="gobject-Type-Information.html#GType" title="GType"><span class="type">GType</span></a> identifying the owner of <em class="parameter"><code>pspec</code></em>
1483
<div class="refsect2" lang="en">
1484
<a name="g-param-spec-pool-remove"></a><h3>g_param_spec_pool_remove ()</h3>
1485
<pre class="programlisting">void g_param_spec_pool_remove (<a class="link" href="gobject-GParamSpec.html#GParamSpecPool" title="GParamSpecPool">GParamSpecPool</a> *pool,
1486
<a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a> *pspec);</pre>
1488
Removes a <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a> from the pool.</p>
1491
<div class="variablelist"><table border="0">
1492
<col align="left" valign="top">
1495
<td><p><span class="term"><em class="parameter"><code>pool</code></em> :</span></p></td>
1496
<td> a <a class="link" href="gobject-GParamSpec.html#GParamSpecPool" title="GParamSpecPool"><span class="type">GParamSpecPool</span></a>
1500
<td><p><span class="term"><em class="parameter"><code>pspec</code></em> :</span></p></td>
1501
<td> the <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a> to remove
1508
<div class="refsect2" lang="en">
1509
<a name="g-param-spec-pool-lookup"></a><h3>g_param_spec_pool_lookup ()</h3>
1510
<pre class="programlisting"><a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec">GParamSpec</a>* g_param_spec_pool_lookup (<a class="link" href="gobject-GParamSpec.html#GParamSpecPool" title="GParamSpecPool">GParamSpecPool</a> *pool,
1564
1512
href="./../glib/glib/glib-Basic-Types.html#gchar"
1565
1513
>gchar</a> *param_name,
1566
<a class="link" href="gobject-Type-Information.html#GType">GType</a> owner_type,
1514
<a class="link" href="gobject-Type-Information.html#GType" title="GType">GType</a> owner_type,
1568
1516
href="./../glib/glib/glib-Basic-Types.html#gboolean"
1569
1517
>gboolean</a> walk_ancestors);</pre>
1571
Looks up a <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a> in the pool.
1519
Looks up a <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a> in the pool.</p>
1573
1522
<div class="variablelist"><table border="0">
1574
1523
<col align="left" valign="top">
1577
<td><p><span class="term"><em class="parameter"><code>pool</code></em> :</span></p></td>
1578
<td>a <a class="link" href="gobject-GParamSpec.html#GParamSpecPool"><span class="type">GParamSpecPool</span></a>
1582
<td><p><span class="term"><em class="parameter"><code>param_name</code></em> :</span></p></td>
1583
<td>the name to look for
1587
<td><p><span class="term"><em class="parameter"><code>owner_type</code></em> :</span></p></td>
1588
<td>the owner to look for
1592
<td><p><span class="term"><em class="parameter"><code>walk_ancestors</code></em> :</span></p></td>
1594
href="./../glib/glib/glib-Standard-Macros.html#TRUE:CAPS"
1595
><code class="literal">TRUE</code></a>, also try to find a <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a> with <em class="parameter"><code>param_name</code></em>
1596
owned by an ancestor of <em class="parameter"><code>owner_type</code></em>.
1600
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1601
<td>The found <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a>, or <a
1602
href="./../glib/glib/glib-Standard-Macros.html#NULL:CAPS"
1603
><code class="literal">NULL</code></a> if no matching <a class="link" href="gobject-GParamSpec.html#GParamSpec"><span class="type">GParamSpec</span></a> was found.
1526
<td><p><span class="term"><em class="parameter"><code>pool</code></em> :</span></p></td>
1527
<td> a <a class="link" href="gobject-GParamSpec.html#GParamSpecPool" title="GParamSpecPool"><span class="type">GParamSpecPool</span></a>
1531
<td><p><span class="term"><em class="parameter"><code>param_name</code></em> :</span></p></td>
1532
<td> the name to look for
1536
<td><p><span class="term"><em class="parameter"><code>owner_type</code></em> :</span></p></td>
1537
<td> the owner to look for
1541
<td><p><span class="term"><em class="parameter"><code>walk_ancestors</code></em> :</span></p></td>
1543
href="./../glib/glib/glib-Standard-Macros.html#TRUE--CAPS"
1544
><code class="literal">TRUE</code></a>, also try to find a <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a> with <em class="parameter"><code>param_name</code></em>
1545
owned by an ancestor of <em class="parameter"><code>owner_type</code></em>.
1549
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1550
<td> The found <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a>, or <a
1551
href="./../glib/glib/glib-Standard-Macros.html#NULL--CAPS"
1552
><code class="literal">NULL</code></a> if no matching <a class="link" href="gobject-GParamSpec.html#GParamSpec" title="GParamSpec"><span class="type">GParamSpec</span></a> was found.