diff options
author | Marcin Kolny <marcin.kolny@gmail.com> | 2015-08-08 14:45:12 +0200 |
---|---|---|
committer | Marcin Kolny <marcin.kolny@gmail.com> | 2015-08-08 14:45:59 +0200 |
commit | 0d5f63b18f5766760cf39e82ee11482984e0a938 (patch) | |
tree | e3f74b9b37e7618c92840024077dff43e6d08f0d /glib/src/glib_docs.xml | |
parent | dce7a844e48a582e42eb2b60eef5c1f2527540ac (diff) | |
parent | d94115843f38967b5e883f5f7d8057882ae364cb (diff) | |
download | glibmm-0d5f63b18f5766760cf39e82ee11482984e0a938.tar.gz |
Merge branch 'master' into glibmm-gir-gmmprocglibmm-gir-gmmproc
Diffstat (limited to 'glib/src/glib_docs.xml')
-rw-r--r-- | glib/src/glib_docs.xml | 2176 |
1 files changed, 2050 insertions, 126 deletions
diff --git a/glib/src/glib_docs.xml b/glib/src/glib_docs.xml index cba1b917..1708607a 100644 --- a/glib/src/glib_docs.xml +++ b/glib/src/glib_docs.xml @@ -1,4 +1,51 @@ <root> +<property name="GBinding:flags"> +<description> +Flags to be used to control the #GBinding + +Since: 2.26 + +</description> +</property> + +<property name="GBinding:source"> +<description> +The #GObject that should be used as the source of the binding + +Since: 2.26 + +</description> +</property> + +<property name="GBinding:source-property"> +<description> +The name of the property of #GBinding:source that should be used +as the source of the binding + +Since: 2.26 + +</description> +</property> + +<property name="GBinding:target"> +<description> +The #GObject that should be used as the target of the binding + +Since: 2.26 + +</description> +</property> + +<property name="GBinding:target-property"> +<description> +The name of the property of #GBinding:target that should be used +as the target of the binding + +Since: 2.26 + +</description> +</property> + <enum name="GBindingFlags"> <description> Flags to be passed to g_object_bind_property() or @@ -1169,8 +1216,8 @@ option: `--name arg` or combined in a single argument: `--name=arg`. </parameter_description> </parameter> <parameter name="G_OPTION_ARG_CALLBACK"> -<parameter_description> The option provides a callback to parse the -extra argument. +<parameter_description> The option provides a callback (of type +#GOptionArgFunc) to parse the extra argument. </parameter_description> </parameter> <parameter name="G_OPTION_ARG_FILENAME"> @@ -1284,7 +1331,7 @@ your direct control. Since 2.8. <enum name="GParamFlags"> <description> Through the #GParamFlags flag values, certain aspects of parameters -can be configured. See also #G_PARAM_READWRITE and #G_PARAM_STATIC_STRINGS. +can be configured. See also #G_PARAM_STATIC_STRINGS. </description> <parameters> @@ -1305,7 +1352,7 @@ can be configured. See also #G_PARAM_READWRITE and #G_PARAM_STATIC_STRINGS. </parameter_description> </parameter> <parameter name="G_PARAM_CONSTRUCT_ONLY"> -<parameter_description> the parameter will only be set upon object construction +<parameter_description> the parameter can only be set upon object construction </parameter_description> </parameter> <parameter name="G_PARAM_LAX_VALIDATION"> @@ -2558,6 +2605,10 @@ Deprecated: 2.36: g_type_init() is now done automatically <parameter_description> Mask covering all debug flags </parameter_description> </parameter> +<parameter name="G_TYPE_DEBUG_INSTANCE_COUNT"> +<parameter_description> Keep a count of instances of each type +</parameter_description> +</parameter> </parameters> </enum> @@ -2807,7 +2858,7 @@ a value never returned from g_unichar_get_script() </parameter> <parameter name="G_UNICODE_SCRIPT_INHERITED"> <parameter_description> a mark glyph that takes its script from the -i base glyph to which it is attached +base glyph to which it is attached </parameter_description> </parameter> <parameter name="G_UNICODE_SCRIPT_ARABIC"> @@ -3310,7 +3361,10 @@ Old South Arabian. Since 2.26 </parameter> <parameter name="G_UNICODE_SCRIPT_TIRHUTA"> <parameter_description> Tirhuta. Since: 2.42 -@G_UNICODE_SCRIPT_WARANG_CITI Warang Citi. Since: 2.42 +</parameter_description> +</parameter> +<parameter name="G_UNICODE_SCRIPT_WARANG_CITI"> +<parameter_description> Warang Citi. Since: 2.42 </parameter_description> </parameter> </parameters> @@ -3666,6 +3720,30 @@ Error codes returned by parsing text-format GVariants. </parameters> </enum> +<enum name="GWin32OSType"> +<description> +Type of Windows edition to check for at run-time. + +</description> +<parameters> +<parameter name="G_WIN32_OS_ANY"> +<parameter_description> The running system can be a workstation or a server edition of +Windows. The type of the running system is therefore not checked. +</parameter_description> +</parameter> +<parameter name="G_WIN32_OS_WORKSTATION"> +<parameter_description> The running system is a workstation edition of Windows, +such as Windows 7 Professional. +</parameter_description> +</parameter> +<parameter name="G_WIN32_OS_SERVER"> +<parameter_description> The running system is a server edition of Windows, such as +Windows Server 2008 R2. +</parameter_description> +</parameter> +</parameters> +</enum> + <function name="g_access"> <description> A wrapper for the POSIX access() function. This function is used to @@ -4280,7 +4358,8 @@ This function generates enough precision that converting the string back using g_ascii_strtod() gives the same machine-number (on machines with IEEE compatible 64bit doubles). It is guaranteed that the size of the resulting string will never -be larger than @G_ASCII_DTOSTR_BUF_SIZE bytes. +be larger than @G_ASCII_DTOSTR_BUF_SIZE bytes, including the terminating +nul character, which is always added. </description> @@ -4309,6 +4388,8 @@ decimal point. To format the number you pass in a printf()-style format string. Allowed conversion specifiers are 'e', 'E', 'f', 'F', 'g' and 'G'. +The returned buffer is guaranteed to be nul-terminated. + If you just want to want to serialize the value into a string, use g_ascii_dtostr(). @@ -5387,6 +5468,54 @@ Pushes the @data into the @queue. @data must not be %NULL. <return></return> </function> +<function name="g_async_queue_push_front"> +<description> +Pushes the @data into the @queue. @data must not be %NULL. +In contrast to g_async_queue_push(), this function +pushes the new item ahead of the items already in the queue, +so that it will be the next one to be popped off the queue. + +Since: 2.46 + +</description> +<parameters> +<parameter name="queue"> +<parameter_description> a #GAsyncQueue +</parameter_description> +</parameter> +<parameter name="data"> +<parameter_description> @data to push into the @queue +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + +<function name="g_async_queue_push_front_unlocked"> +<description> +Pushes the @data into the @queue. @data must not be %NULL. +In contrast to g_async_queue_push_unlocked(), this function +pushes the new item ahead of the items already in the queue, +so that it will be the next one to be popped off the queue. + +This function must be called while holding the @queue's lock. + +Since: 2.46 + +</description> +<parameters> +<parameter name="queue"> +<parameter_description> a #GAsyncQueue +</parameter_description> +</parameter> +<parameter name="data"> +<parameter_description> @data to push into the @queue +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_async_queue_push_sorted"> <description> Inserts @data into @queue using @func to determine the new @@ -5521,6 +5650,52 @@ lock. <return></return> </function> +<function name="g_async_queue_remove"> +<description> +Remove an item from the queue. This function does not block. + +Since: 2.46 + +</description> +<parameters> +<parameter name="queue"> +<parameter_description> a #GAsyncQueue +</parameter_description> +</parameter> +<parameter name="data"> +<parameter_description> the @data to remove from the @queue +</parameter_description> +</parameter> +</parameters> +<return> %TRUE if the item was removed + +</return> +</function> + +<function name="g_async_queue_remove_unlocked"> +<description> +Remove an item from the queue. This function does not block. + +This function must be called while holding the @queue's lock. + +Since: 2.46 + +</description> +<parameters> +<parameter name="queue"> +<parameter_description> a #GAsyncQueue +</parameter_description> +</parameter> +<parameter name="data"> +<parameter_description> the @data to remove from the @queue +</parameter_description> +</parameter> +</parameters> +<return> %TRUE if the item was removed + +</return> +</function> + <function name="g_async_queue_sort"> <description> Sorts @queue using @func. @@ -6297,6 +6472,168 @@ Since: 2.30 </return> </function> +<function name="g_auto"> +<description> +Helper to declare a variable with automatic cleanup. + +The variable is cleaned up in a way appropriate to its type when the +variable goes out of scope. The type must support this. + +This feature is only supported on GCC and clang. This macro is not +defined on other compilers and should not be used in programs that +are intended to be portable to those compilers. + +This is meant to be used with stack-allocated structures and +non-pointer types. For the (more commonly used) pointer version, see +g_autoptr(). + +This macro can be used to avoid having to do explicit cleanups of +local variables when exiting functions. It often vastly simplifies +handling of error conditions, removing the need for various tricks +such as 'goto out' or repeating of cleanup code. It is also helpful +for non-error cases. + +Consider the following example: + +|[ +GVariant * +my_func(void) +{ +g_auto(GQueue) queue = G_QUEUE_INIT; +g_auto(GVariantBuilder) builder; + +g_variant_builder_init (&builder, G_VARIANT_TYPE_VARDICT); + +... + +if (error_condition) +return NULL; + +... + +return g_variant_builder_end (&builder); +} +]| + +You must initialise the variable in some way -- either by use of an +initialiser or by ensuring that an _init function will be called on +it unconditionally before it goes out of scope. + +Since: 2.44 + +</description> +<parameters> +<parameter name="TypeName"> +<parameter_description> a supported variable type +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + +<function name="g_autofree"> +<description> +Macro to add an attribute to pointer variable to ensure automatic +cleanup using g_free(). + +This macro differs from g_autoptr() in that it is an attribute supplied +before the type name, rather than wrapping the type definition. Instead +of using a type-specific lookup, this macro always calls g_free() directly. + +This means it's useful for any type that is returned from +g_malloc(). + +Otherwise, this macro has similar constraints as g_autoptr() - only +supported on GCC and clang, the variable must be initialized, etc. + +|[ +gboolean +operate_on_malloc_buf (void) +{ +g_autofree guint8* membuf = NULL; + +membuf = g_malloc (8192); + +/ * Some computation on membuf * / + +/ * membuf will be automatically freed here * / +return TRUE; +} +]| + +Since: 2.44 + +</description> +<parameters> +</parameters> +<return></return> +</function> + +<function name="g_autoptr"> +<description> +Helper to declare a pointer variable with automatic cleanup. + +The variable is cleaned up in a way appropriate to its type when the +variable goes out of scope. The type must support this. + +This feature is only supported on GCC and clang. This macro is not +defined on other compilers and should not be used in programs that +are intended to be portable to those compilers. + +This is meant to be used to declare pointers to types with cleanup +functions. The type of the variable is a pointer to @TypeName. You +must not add your own '*'. + +This macro can be used to avoid having to do explicit cleanups of +local variables when exiting functions. It often vastly simplifies +handling of error conditions, removing the need for various tricks +such as 'goto out' or repeating of cleanup code. It is also helpful +for non-error cases. + +Consider the following example: + +|[ +gboolean +check_exists(GVariant *dict) +{ +g_autoptr(GVariant) dirname; +g_autoptr(GVariant) basename = NULL; +g_autoptr(gchar) path = NULL; + +dirname = g_variant_lookup_value (dict, "dirname", G_VARIANT_TYPE_STRING); + +if (dirname == NULL) +return FALSE; + +basename = g_variant_lookup_value (dict, "basename", G_VARIANT_TYPE_STRING); + +if (basename == NULL) +return FALSE; + +path = g_build_filename (g_variant_get_string (dirname, NULL), +g_variant_get_string (basename, NULL), +NULL); + +return g_access (path, R_OK) == 0; +} +]| + +You must initialise the variable in some way -- either by use of an +initialiser or by ensuring that it is assigned to unconditionally +before it goes out of scope. + +Since: 2.44 + +</description> +<parameters> +<parameter name="TypeName"> +<parameter_description> a supported variable type +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_base64_decode"> <description> Decode a sequence of Base-64 encoded text into binary data. Note @@ -9094,6 +9431,91 @@ data structures to @func; use g_cache_key_foreach() instead <return></return> </function> +<function name="g_cclosure_marshal_BOOLEAN__BOXED_BOXED"> +<description> +A #GClosureMarshal function for use with signals with handlers that +take two boxed pointers as arguments and return a boolean. If you +have such a signal, you will probably also need to use an +accumulator, such as g_signal_accumulator_true_handled(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> A #GClosure. +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> A #GValue to store the return value. May be %NULL +if the callback of closure doesn't return a value. +</parameter_description> +</parameter> +<parameter name="n_param_values"> +<parameter_description> The length of the @param_values array. +</parameter_description> +</parameter> +<parameter name="param_values"> +<parameter_description> An array of #GValues holding the arguments +on which to invoke the callback of closure. +</parameter_description> +</parameter> +<parameter name="invocation_hint"> +<parameter_description> The invocation hint given as the last argument to +g_closure_invoke(). +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> Additional data specified when registering the +marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + +<function name="g_cclosure_marshal_BOOLEAN__BOXED_BOXEDv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_BOOLEAN__BOXED_BOXED(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_BOOLEAN__FLAGS"> <description> A marshaller for a #GCClosure with a callback of type @@ -9131,6 +9553,49 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_BOOLEAN__FLAGSv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_BOOLEAN__FLAGS(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_BOOLEAN__OBJECT_BOXED_BOXED"> <description> A marshaller for a #GCClosure with a callback of type @@ -9169,6 +9634,45 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_BOOL__BOXED_BOXED"> +<description> +An old alias for g_cclosure_marshal_BOOLEAN__BOXED_BOXED(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> A #GClosure. +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> A #GValue to store the return value. May be %NULL +if the callback of closure doesn't return a value. +</parameter_description> +</parameter> +<parameter name="n_param_values"> +<parameter_description> The length of the @param_values array. +</parameter_description> +</parameter> +<parameter name="param_values"> +<parameter_description> An array of #GValues holding the arguments +on which to invoke the callback of closure. +</parameter_description> +</parameter> +<parameter name="invocation_hint"> +<parameter_description> The invocation hint given as the last argument to +g_closure_invoke(). +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> Additional data specified when registering the +marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_BOOL__FLAGS"> <description> Another name for g_cclosure_marshal_BOOLEAN__FLAGS(). @@ -9215,6 +9719,49 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_STRING__OBJECT_POINTERv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_STRING__OBJECT_POINTER(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_VOID__BOOLEAN"> <description> A marshaller for a #GCClosure with a callback of type @@ -9251,6 +9798,49 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_VOID__BOOLEANv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_VOID__BOOLEAN(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_VOID__BOXED"> <description> A marshaller for a #GCClosure with a callback of type @@ -9287,6 +9877,49 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_VOID__BOXEDv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_VOID__BOXED(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_VOID__CHAR"> <description> A marshaller for a #GCClosure with a callback of type @@ -9323,6 +9956,49 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_VOID__CHARv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_VOID__CHAR(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_VOID__DOUBLE"> <description> A marshaller for a #GCClosure with a callback of type @@ -9359,6 +10035,49 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_VOID__DOUBLEv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_VOID__DOUBLE(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_VOID__ENUM"> <description> A marshaller for a #GCClosure with a callback of type @@ -9395,6 +10114,49 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_VOID__ENUMv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_VOID__ENUM(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_VOID__FLAGS"> <description> A marshaller for a #GCClosure with a callback of type @@ -9431,6 +10193,49 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_VOID__FLAGSv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_VOID__FLAGS(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_VOID__FLOAT"> <description> A marshaller for a #GCClosure with a callback of type @@ -9467,6 +10272,49 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_VOID__FLOATv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_VOID__FLOAT(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_VOID__INT"> <description> A marshaller for a #GCClosure with a callback of type @@ -9503,6 +10351,49 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_VOID__INTv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_VOID__INT(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_VOID__LONG"> <description> A marshaller for a #GCClosure with a callback of type @@ -9539,6 +10430,49 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_VOID__LONGv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_VOID__LONG(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_VOID__OBJECT"> <description> A marshaller for a #GCClosure with a callback of type @@ -9575,6 +10509,49 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_VOID__OBJECTv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_VOID__OBJECT(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_VOID__PARAM"> <description> A marshaller for a #GCClosure with a callback of type @@ -9611,6 +10588,49 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_VOID__PARAMv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_VOID__PARAM(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_VOID__POINTER"> <description> A marshaller for a #GCClosure with a callback of type @@ -9647,6 +10667,49 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_VOID__POINTERv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_VOID__POINTER(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_VOID__STRING"> <description> A marshaller for a #GCClosure with a callback of type @@ -9683,6 +10746,49 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_VOID__STRINGv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_VOID__STRING(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_VOID__UCHAR"> <description> A marshaller for a #GCClosure with a callback of type @@ -9719,6 +10825,49 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_VOID__UCHARv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_VOID__UCHAR(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_VOID__UINT"> <description> A marshaller for a #GCClosure with a callback of type @@ -9791,6 +10940,92 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_VOID__UINT_POINTERv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_VOID__UINT_POINTER(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + +<function name="g_cclosure_marshal_VOID__UINTv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_VOID__UINT(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_VOID__ULONG"> <description> A marshaller for a #GCClosure with a callback of type @@ -9827,6 +11062,49 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_VOID__ULONGv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_VOID__ULONG(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_VOID__VARIANT"> <description> A marshaller for a #GCClosure with a callback of type @@ -9865,6 +11143,49 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_VOID__VARIANTv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_VOID__VARIANT(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_VOID__VOID"> <description> A marshaller for a #GCClosure with a callback of type @@ -9901,6 +11222,49 @@ to g_closure_invoke() <return></return> </function> +<function name="g_cclosure_marshal_VOID__VOIDv"> +<description> +The #GVaClosureMarshal equivalent to g_cclosure_marshal_VOID__VOID(). + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_marshal_generic"> <description> A generic marshaller function implemented via @@ -9946,6 +11310,52 @@ g_closure_set_meta_marshal() <return></return> </function> +<function name="g_cclosure_marshal_generic_va"> +<description> +A generic #GVaClosureMarshal function implemented via +[libffi](http://sourceware.org/libffi/). + +Since: 2.30 + +</description> +<parameters> +<parameter name="closure"> +<parameter_description> the #GClosure to which the marshaller belongs +</parameter_description> +</parameter> +<parameter name="return_value"> +<parameter_description> a #GValue to store the return +value. May be %NULL if the callback of @closure doesn't return a +value. +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> the instance on which the closure is invoked. +</parameter_description> +</parameter> +<parameter name="args_list"> +<parameter_description> va_list of arguments to be passed to the closure. +</parameter_description> +</parameter> +<parameter name="marshal_data"> +<parameter_description> additional data specified when +registering the marshaller, see g_closure_set_marshal() and +g_closure_set_meta_marshal() +</parameter_description> +</parameter> +<parameter name="n_params"> +<parameter_description> the length of the @param_types array +</parameter_description> +</parameter> +<parameter name="param_types"> +<parameter_description> the #GType of each argument from +@args_list. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_cclosure_new"> <description> Creates a new closure which invokes @callback_func with @user_data as @@ -10513,7 +11923,9 @@ Since: 2.36 </parameter_description> </parameter> </parameters> -<return></return> +<return> %TRUE on success, %FALSE if there was an error. + +</return> </function> <function name="g_closure_add_finalize_notifier"> @@ -12800,8 +14212,8 @@ etc. The date must be valid. <function name="g_date_get_monday_week_of_year"> <description> Returns the week of the year, where weeks are understood to start on -Monday. If the date is before the first Monday of the year, return -0. The date must be valid. +Monday. If the date is before the first Monday of the year, return 0. +The date must be valid. </description> @@ -12855,9 +14267,9 @@ Returns the month of the year. The date must be valid. <function name="g_date_get_sunday_week_of_year"> <description> -Returns the week of the year during which this date falls, if weeks -are understood to being on Sunday. The date must be valid. Can return -0 if the day is before the first Sunday of the year. +Returns the week of the year during which this date falls, if +weeks are understood to being on Sunday. The date must be valid. +Can return 0 if the day is before the first Sunday of the year. </description> @@ -13695,7 +15107,7 @@ The following format specifiers are supported: - \%A: the full weekday name according to the current locale - \%b: the abbreviated month name according to the current locale - \%B: the full month name according to the current locale -- \%c: the preferred date and time rpresentation for the current locale +- \%c: the preferred date and time representation for the current locale - \%C: the century number (year/100) as a 2-digit integer (00-99) - \%d: the day of the month as a decimal number (range 01 to 31) - \%e: the day of the month as a decimal number (range 1 to 31) @@ -14024,7 +15436,7 @@ this may mean that the week-numbering year is one greater than the calendar year (so that these days have the same week-numbering year as the Thursday occurring early in the next year). -For Friday, Saturaday and Sunday occurring near the start of the year, +For Friday, Saturday and Sunday occurring near the start of the year, this may mean that the week-numbering year is one less than the calendar year (so that these days have the same week-numbering year as the Thursday occurring late in the previous year). @@ -15419,8 +16831,7 @@ for an empty environment list </parameter_description> </parameter> <parameter name="variable"> -<parameter_description> the environment variable to get, in the GLib file name -encoding +<parameter_description> the environment variable to get </parameter_description> </parameter> </parameters> @@ -15558,7 +16969,7 @@ be returned. If @domain contains a `FAILED` (or otherwise generic) error code, you should generally not check for it explicitly, but should instead treat any not-explicitly-recognized error code as being -equilalent to the `FAILED` code. This way, if the domain is +equivalent to the `FAILED` code. This way, if the domain is extended in the future to provide a more specific error code for a certain case, your code will still work. @@ -16428,7 +17839,9 @@ Since: 2.2 <function name="g_free"> <description> Frees the memory pointed to by @mem. -If @mem is %NULL it simply returns. + +If @mem is %NULL it simply returns, so there is no need to check @mem +against %NULL before calling this function. </description> <parameters> @@ -16513,7 +17926,8 @@ freed. </description> <parameters> <parameter name="charset"> -<parameter_description> return location for character set name +<parameter_description> return location for character set +name, or %NULL. </parameter_description> </parameter> </parameters> @@ -17087,9 +18501,9 @@ GLib and should not be modified or freed. <description> Returns the value of an environment variable. -The name and value are in the GLib file name encoding. On UNIX, -this means the actual bytes which might or might not be in some -consistent character set and encoding. On Windows, it is in UTF-8. +On UNIX, the name and value are byte strings which might or might not +be in some consistent character set and encoding. On Windows, they are +in UTF-8. On Windows, in case the environment variable's value contains references to other environment variables, they are expanded. @@ -17097,8 +18511,7 @@ references to other environment variables, they are expanded. </description> <parameters> <parameter name="variable"> -<parameter_description> the environment variable to get, in the GLib file name -encoding +<parameter_description> the environment variable to get </parameter_description> </parameter> </parameters> @@ -17154,7 +18567,9 @@ Since: 2.32 </parameter_description> </parameter> </parameters> -<return></return> +<return> %TRUE if @key is in @hash_table, %FALSE otherwise. + +</return> </function> <function name="g_hash_table_destroy"> @@ -17327,6 +18742,10 @@ release of GLib. It does nothing. Retrieves every key inside @hash_table. The returned data is valid until changes to the hash release those keys. +This iterates over every entry in the hash table to build its return value. +To iterate over the entries in a #GHashTable more efficiently, use a +#GHashTableIter. + Since: 2.14 </description> @@ -17353,7 +18772,11 @@ key. Use @length to determine the true length if it's possible that %NULL was used as the value for a key. Note: in the common case of a string-keyed #GHashTable, the return -value of this function can be conveniently cast to (gchar **). +value of this function can be conveniently cast to (const gchar **). + +This iterates over every entry in the hash table to build its return value. +To iterate over the entries in a #GHashTable more efficiently, use a +#GHashTableIter. You should always free the return result with g_free(). In the above-mentioned case of a string-keyed hash table, it may be @@ -17384,6 +18807,10 @@ Since: 2.40 Retrieves every value inside @hash_table. The returned data is valid until @hash_table is modified. +This iterates over every entry in the hash table to build its return value. +To iterate over the entries in a #GHashTable more efficiently, use a +#GHashTableIter. + Since: 2.14 </description> @@ -17686,6 +19113,13 @@ count of 1 and allows to specify functions to free the memory allocated for the key and value that get called when removing the entry from the #GHashTable. +Since version 2.42 it is permissible for destroy notify functions to +recursively remove further items from the hash table. This is only +permissible if the application still holds a reference to the hash table. +This means that you may need to ensure that the hash table is empty by +calling g_hash_table_remove_all before releasing the last reference using +g_hash_table_unref(). + </description> <parameters> @@ -18857,8 +20291,10 @@ returns %FALSE it is automatically removed from the list of event sources and will not be called again. This internally creates a main loop source using g_idle_source_new() -and attaches it to the main loop context using g_source_attach(). -You can do these steps manually if you need greater control. +and attaches it to the global #GMainContext using g_source_attach(), so +the callback will be invoked in whichever thread is running that main +context. You can do these steps manually if you need greater control or to +use a custom main context. </description> @@ -18883,8 +20319,10 @@ events pending. If the function returns %FALSE it is automatically removed from the list of event sources and will not be called again. This internally creates a main loop source using g_idle_source_new() -and attaches it to the main loop context using g_source_attach(). -You can do these steps manually if you need greater control. +and attaches it to the global #GMainContext using g_source_attach(), so +the callback will be invoked in whichever thread is running that main +context. You can do these steps manually if you need greater control or to +use a custom main context. </description> @@ -20283,10 +21721,12 @@ should be freed with g_free() when no longer needed. <function name="g_key_file_get_comment"> <description> Retrieves a comment above @key from @group_name. -If @key is %NULL then @comment will be read from above -@group_name. If both @key and @group_name are %NULL, then +If @key is %NULL then @comment will be read from above +@group_name. If both @key and @group_name are %NULL, then @comment will be read from above the first group in the file. +Note that the returned string includes the '#' comment markers. + Since: 2.6 </description> @@ -21254,10 +22694,14 @@ Since: 2.6 <function name="g_key_file_set_comment"> <description> Places a comment above @key from @group_name. -If @key is %NULL then @comment will be written above @group_name. -If both @key and @group_name are %NULL, then @comment will be + +If @key is %NULL then @comment will be written above @group_name. +If both @key and @group_name are %NULL, then @comment will be written above the first group in the file. +Note that this function prepends a '#' comment marker to +each line of @comment. + Since: 2.6 </description> @@ -22002,7 +23446,10 @@ Another name for g_list_free_1(). <function name="g_list_free_1"> <description> -Frees one #GList element. +Frees one #GList element, but does not update links from the next and +previous elements in the list, so you should not call this function on an +element that is currently part of a list. + It is usually used after g_list_remove_link(). </description> @@ -22204,7 +23651,8 @@ Gets the number of elements in a #GList. This function iterates over the whole list to count its elements. Use a #GQueue instead of a GList if you regularly need the number -of items. +of items. To check whether the list is non-empty, it is faster to check +@list against %NULL. </description> @@ -22240,6 +23688,10 @@ Note that it is considered perfectly acceptable to access <description> Gets the element at the given position in a #GList. +This iterates over the list until it reaches the @n-th position. If you +intend to iterate over every element, it is better to use a for-loop as +described in the #GList introduction. + </description> <parameters> @@ -22261,6 +23713,10 @@ the end of the #GList <description> Gets the data of the element at the given position. +This iterates over the list until it reaches the @n-th position. If you +intend to iterate over every element, it is better to use a for-loop as +described in the #GList introduction. + </description> <parameters> @@ -22864,6 +24320,44 @@ the log levels with the #G_LOG_FLAG_FATAL and </return> </function> +<function name="g_log_set_handler_full"> +<description> +Like g_log_sets_handler(), but takes a destroy notify for the @user_data. + +Since: 2.46 + +</description> +<parameters> +<parameter name="log_domain"> +<parameter_description> the log domain, or %NULL for the default "" +application domain +</parameter_description> +</parameter> +<parameter name="log_levels"> +<parameter_description> the log levels to apply the log handler for. +To handle fatal and recursive messages as well, combine +the log levels with the #G_LOG_FLAG_FATAL and +#G_LOG_FLAG_RECURSION bit flags. +</parameter_description> +</parameter> +<parameter name="log_func"> +<parameter_description> the log handler function +</parameter_description> +</parameter> +<parameter name="user_data"> +<parameter_description> data passed to the log handler +</parameter_description> +</parameter> +<parameter name="destroy"> +<parameter_description> destroy notify for @user_data, or %NULL +</parameter_description> +</parameter> +</parameters> +<return> the id of the new handler + +</return> +</function> + <function name="g_logv"> <description> Logs an error or debugging message. @@ -25910,6 +27404,70 @@ already been locked by the same thread results in undefined behaviour <return></return> </function> +<function name="g_mutex_locker_free"> +<description> +Unlock @locker's mutex. See g_mutex_locker_new() for details. + +Since: 2.44 + +</description> +<parameters> +<parameter name="locker"> +<parameter_description> a GMutexLocker +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + +<function name="g_mutex_locker_new"> +<description> +Lock @mutex and return a new #GMutexLocker. Unlock with +g_mutex_locker_free(). Using g_mutex_unlock() on @mutex +while a #GMutexLocker exists can lead to undefined behaviour. + +This is intended to be used with g_autoptr(). Note that g_autoptr() +is only available when using GCC or clang, so the following example +will only work with those compilers: +|[ +typedef struct +{ +... +GMutex mutex; +... +} MyObject; + +static void +my_object_do_stuff (MyObject *self) +{ +g_autoptr(GMutexLocker) locker = g_mutex_locker_new (&self->mutex); + +// Code with mutex locked here + +if (cond) +// No need to unlock +return; + +// Optionally early unlock +g_clear_pointer (&locker, g_mutex_locker_free); + +// Code with mutex unlocked here +} +]| + +Since: 2.44 + +</description> +<parameters> +<parameter name="mutex"> +<parameter_description> a mutex to lock +</parameter_description> +</parameter> +</parameters> +<return> a #GMutexLocker +</return> +</function> + <function name="g_mutex_new"> <description> Allocates and initializes a new #GMutex. @@ -28118,7 +29676,7 @@ by @newval, %FALSE otherwise. Releases all references to other objects. This can be used to break reference cycles. -This functions should only be called from object system implementations. +This function should only be called from object system implementations. </description> <parameters> @@ -28420,6 +29978,11 @@ It is an error to call this function when the freeze count is zero. Decreases the reference count of @object. When its reference count drops to 0, the object is finalized (i.e. its memory is freed). +If the pointer to the #GObject may be reused in future (for example, if it is +an instance variable of another object), it is recommended to clear the +pointer to %NULL rather than retain a dangling pointer to a potentially +invalid #GObject instance. Use g_clear_object() for this. + </description> <parameters> <parameter name="object"> @@ -28749,10 +30312,8 @@ from open(). <function name="g_option_context_add_group"> <description> Adds a #GOptionGroup to the @context, so that parsing with @context -will recognize the options in the group. Note that the group will -be freed together with the context when g_option_context_free() is -called, so you must not free the group yourself after adding it -to a context. +will recognize the options in the group. Note that this will take +ownership of the @group and thus the @group should not be freed. Since: 2.6 @@ -28918,9 +30479,29 @@ Since: 2.6 </parameter_description> </parameter> </parameters> -<return> the main group of @context, or %NULL if @context doesn't -have a main group. Note that group belongs to @context and should -not be modified or freed. +<return> the main group of @context, or %NULL if +@context doesn't have a main group. Note that group belongs to +@context and should not be modified or freed. + +</return> +</function> + +<function name="g_option_context_get_strict_posix"> +<description> +Returns whether strict POSIX code is enabled. + +See g_option_context_set_strict_posix() for more information. + +Since: 2.44 + +</description> +<parameters> +<parameter name="context"> +<parameter_description> a #GoptionContext +</parameter_description> +</parameter> +</parameters> +<return> %TRUE if strict POSIX is enabled, %FALSE otherwise. </return> </function> @@ -29174,6 +30755,49 @@ Since: 2.6 <return></return> </function> +<function name="g_option_context_set_strict_posix"> +<description> +Sets strict POSIX mode. + +By default, this mode is disabled. + +In strict POSIX mode, the first non-argument parameter encountered +(eg: filename) terminates argument processing. Remaining arguments +are treated as non-options and are not attempted to be parsed. + +If strict POSIX mode is disabled then parsing is done in the GNU way +where option arguments can be freely mixed with non-options. + +As an example, consider "ls foo -l". With GNU style parsing, this +will list "foo" in long mode. In strict POSIX style, this will list +the files named "foo" and "-l". + +It may be useful to force strict POSIX mode when creating "verb +style" command line tools. For example, the "gsettings" command line +tool supports the global option "--schemadir" as well as many +subcommands ("get", "set", etc.) which each have their own set of +arguments. Using strict POSIX mode will allow parsing the global +options up to the verb name while leaving the remaining options to be +parsed by the relevant subcommand (which can be determined by +examining the verb name, which should be present in argv[1] after +parsing). + +Since: 2.44 + +</description> +<parameters> +<parameter name="context"> +<parameter_description> a #GoptionContext +</parameter_description> +</parameter> +<parameter name="strict_posix"> +<parameter_description> the new value +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_option_context_set_summary"> <description> Adds a string to be displayed in `--help` output before the list @@ -29286,6 +30910,8 @@ which have been added to a #GOptionContext. Since: 2.6 +Deprecated: 2.44: Use g_option_group_unref() instead. + </description> <parameters> <parameter name="group"> @@ -29332,7 +30958,25 @@ the error hook and to callbacks of %G_OPTION_ARG_CALLBACK options, or %NULL </parameter> </parameters> <return> a newly created option group. It should be added -to a #GOptionContext or freed with g_option_group_free(). +to a #GOptionContext or freed with g_option_group_unref(). + +</return> +</function> + +<function name="g_option_group_ref"> +<description> +Increments the reference count of @group by one. + +Since: 2.44 + +</description> +<parameters> +<parameter name="group"> +<parameter_description> a #GOptionGroup +</parameter_description> +</parameter> +</parameters> +<return> a #GoptionGroup </return> </function> @@ -29445,30 +31089,31 @@ Since: 2.6 <return></return> </function> -<function name="g_param_get_default_value"> +<function name="g_option_group_unref"> <description> -Gets the default value of @param as a pointer to a #GValue. +Decrements the reference count of @group by one. +If the reference count drops to 0, the @group will be freed. +and all memory allocated by the @group is released. -The #GValue will remain value for the life of @param. - -Since: 2.38 +Since: 2.44 </description> <parameters> -<parameter name="param"> -<parameter_description> a #GParamSpec +<parameter name="group"> +<parameter_description> a #GOptionGroup </parameter_description> </parameter> </parameters> -<return> a pointer to a #GValue which must not be modified - -</return> +<return></return> </function> <function name="g_param_spec_boolean"> <description> Creates a new #GParamSpecBoolean instance specifying a %G_TYPE_BOOLEAN -property. +property. In many cases, it may be more appropriate to use an enum with +g_param_spec_enum(), both to improve code clarity by using explicitly named +values, and to allow for more values to be added in future without breaking +API. See g_param_spec_internal() for details on property names. @@ -29754,6 +31399,26 @@ Get the short description of a #GParamSpec. </return> </function> +<function name="g_param_spec_get_default_value"> +<description> +Gets the default value of @param as a pointer to a #GValue. + +The #GValue will remain value for the life of @param. + +Since: 2.38 + +</description> +<parameters> +<parameter name="param"> +<parameter_description> a #GParamSpec +</parameter_description> +</parameter> +</parameters> +<return> a pointer to a #GValue which must not be modified + +</return> +</function> + <function name="g_param_spec_get_name"> <description> Get the name of a #GParamSpec. @@ -30143,6 +31808,8 @@ See g_param_spec_internal() for details on property names. <function name="g_param_spec_pointer"> <description> Creates a new #GParamSpecPointer instance specifying a pointer property. +Where possible, it is better to use g_param_spec_object() or +g_param_spec_boxed() to expose memory management information. See g_param_spec_internal() for details on property names. @@ -31560,6 +33227,10 @@ the #GDestroyNotify for @key is not called on the old value. If @dest is %NULL, free @src; otherwise, moves @src into *@dest. The error variable @dest points to must be %NULL. +Note that @src is no longer valid after this call. If you want +to keep using the same GError*, you need to set it to %NULL +after calling this function on it. + </description> <parameters> <parameter name="dest"> @@ -32429,9 +34100,10 @@ Since: 2.14 <function name="g_queue_insert_after"> <description> -Inserts @data into @queue after @sibling +Inserts @data into @queue after @sibling. -@sibling must be part of @queue +@sibling must be part of @queue. Since GLib 2.44 a %NULL sibling pushes the +data at the head of the queue. Since: 2.4 @@ -32442,7 +34114,8 @@ Since: 2.4 </parameter_description> </parameter> <parameter name="sibling"> -<parameter_description> a #GList link that must be part of @queue +<parameter_description> a #GList link that must be part of @queue, or %NULL to +push at the head of the queue. </parameter_description> </parameter> <parameter name="data"> @@ -32457,7 +34130,8 @@ Since: 2.4 <description> Inserts @data into @queue before @sibling. -@sibling must be part of @queue. +@sibling must be part of @queue. Since GLib 2.44 a %NULL sibling pushes the +data at the tail of the queue. Since: 2.4 @@ -32468,7 +34142,8 @@ Since: 2.4 </parameter_description> </parameter> <parameter name="sibling"> -<parameter_description> a #GList link that must be part of @queue +<parameter_description> a #GList link that must be part of @queue, or %NULL to +push at the tail of the queue. </parameter_description> </parameter> <parameter name="data"> @@ -36765,6 +38440,52 @@ Since: 2.18 <return></return> </function> +<function name="g_set_object"> +<description> +Updates a #GObject pointer to refer to @new_object. It increments the +reference count of @new_object (if non-%NULL), decrements the reference +count of the current value of @object_ptr (if non-%NULL), and assigns +@new_object to @object_ptr. The assignment is not atomic. + +@object_ptr must not be %NULL. + +A macro is also included that allows this function to be used without +pointer casts. The function itself is static inline, so its address may vary +between compilation units. + +One convenient usage of this function is in implementing property setters: +|[ +void +foo_set_bar (Foo *foo, +Bar *new_bar) +{ +g_return_if_fail (IS_FOO (foo)); +g_return_if_fail (new_bar == NULL || IS_BAR (new_bar)); + +if (g_set_object (&foo->bar, new_bar)) +g_object_notify (foo, "bar"); +} +]| + +Since: 2.44 + +</description> +<parameters> +<parameter name="object_ptr"> +<parameter_description> a pointer to a #GObject reference +</parameter_description> +</parameter> +<parameter name="new_object"> +<parameter_description> a pointer to the new #GObject to +assign to it, or %NULL to clear the pointer +</parameter_description> +</parameter> +</parameters> +<return> %TRUE if the value of @object_ptr changed, %FALSE otherwise + +</return> +</function> + <function name="g_set_prgname"> <description> Sets the name of the program. This name should not be localized, @@ -36828,10 +38549,9 @@ example. <function name="g_setenv"> <description> -Sets an environment variable. Both the variable's name and value -should be in the GLib file name encoding. On UNIX, this means that -they can be arbitrary byte strings. On Windows, they should be in -UTF-8. +Sets an environment variable. On UNIX, both the variable's name and +value can be arbitrary byte strings, except that the variable's name +cannot contain '='. On Windows, they should be in UTF-8. Note that on some systems, when variables are overwritten, the memory used for the previous variables and its value isn't reclaimed. @@ -37493,7 +39213,9 @@ is being emitted on. The rest are any arguments to be passed to the signal. </parameter_description> </parameter> <parameter name="return_value"> -<parameter_description> Location to store the return value of the signal emission. +<parameter_description> Location to +store the return value of the signal emission. This must be provided if the +specified signal returns a value, but may be ignored otherwise. </parameter_description> </parameter> </parameters> @@ -37917,6 +39639,12 @@ and/or @data the handlers have to match. Returns whether there are any handlers connected to @instance for the given signal id and detail. +If @detail is 0 then it will only match handlers that were connected +without detail. If @detail is non-zero then it will match handlers +connected both without detail and with the given detail. This is +consistent with how a signal emitted with @detail would be delivered +to those handlers. + One example of when you might use this is when the arguments to the signal are difficult to compute. A class implementor may opt to not emit the signal if no one is attached anyway, thus saving the cost @@ -38427,6 +40155,33 @@ g_signal_add_emission_hook() <return></return> </function> +<function name="g_signal_set_va_marshaller"> +<description> +Change the #GSignalCVaMarshaller used for a given signal. This is a +specialised form of the marshaller that can often be used for the +common case of a single connected signal handler and avoids the +overhead of #GValue. Its use is optional. + +Since: 2.32 + +</description> +<parameters> +<parameter name="signal_id"> +<parameter_description> the signal id +</parameter_description> +</parameter> +<parameter name="instance_type"> +<parameter_description> the instance type on which to set the marshaller. +</parameter_description> +</parameter> +<parameter name="va_marshaller"> +<parameter_description> the marshaller to set. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_signal_stop_emission"> <description> Stops a signal's current emission. @@ -39231,7 +40986,8 @@ or %NULL if the #GSList has no elements Gets the number of elements in a #GSList. This function iterates over the whole list to -count its elements. +count its elements. To check whether the list is non-empty, it is faster to +check @list against %NULL. </description> @@ -41582,6 +43338,69 @@ Deprectated: 2.32: Use g_rw_lock_writer_unlock() instead <return></return> </function> +<function name="g_steal_pointer"> +<description> +Sets @pp to %NULL, returning the value that was there before. + +Conceptually, this transfers the ownership of the pointer from the +referenced variable to the "caller" of the macro (ie: "steals" the +reference). + +The return value will be properly typed, according to the type of +@pp. + +This can be very useful when combined with g_autoptr() to prevent the +return value of a function from being automatically freed. Consider +the following example (which only works on GCC and clang): + +|[ +GObject * +create_object (void) +{ +g_autoptr(GObject) obj = g_object_new (G_TYPE_OBJECT, NULL); + +if (early_error_case) +return NULL; + +return g_steal_pointer (&obj); +} +]| + +It can also be used in similar ways for 'out' parameters and is +particularly useful for dealing with optional out parameters: + +|[ +gboolean +get_object (GObject **obj_out) +{ +g_autoptr(GObject) obj = g_object_new (G_TYPE_OBJECT, NULL); + +if (early_error_case) +return FALSE; + +if (obj_out) +*obj_out = g_steal_pointer (&obj); + +return TRUE; +} +]| + +In the above example, the object will be automatically freed in the +early error case and also in the case that %NULL was given for +@obj_out. + +Since: 2.44 + +</description> +<parameters> +<parameter name="pp"> +<parameter_description> a pointer to a pointer +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_stpcpy"> <description> Copies a nul-terminated string into the dest buffer, include the @@ -42231,8 +44050,10 @@ characters escaped. See above. <function name="g_strfreev"> <description> -Frees a %NULL-terminated array of strings, and the array itself. -If called on a %NULL value, g_strfreev() simply returns. +Frees a %NULL-terminated array of strings, as well as each +string it contains. + +If @str_array is %NULL, this function simply returns. </description> <parameters> @@ -43775,6 +45596,28 @@ or g_utf8_strup() instead. </return> </function> +<function name="g_strv_contains"> +<description> +Checks if @strv contains @str. @strv must not be %NULL. + +Since: 2.44 + +</description> +<parameters> +<parameter name="strv"> +<parameter_description> a %NULL-terminated array of strings +</parameter_description> +</parameter> +<parameter name="str"> +<parameter_description> a string +</parameter_description> +</parameter> +</parameters> +<return> %TRUE if @str is an element of @strv, according to g_str_equal(). + +</return> +</function> + <function name="g_strv_length"> <description> Returns the length of the given %NULL-terminated @@ -43797,11 +45640,12 @@ Since: 2.6 <function name="g_test_add"> <description> Hook up a new test case at @testpath, similar to g_test_add_func(). -A fixture data structure with setup and teardown function may be provided -though, similar to g_test_create_case(). +A fixture data structure with setup and teardown functions may be provided, +similar to g_test_create_case(). + g_test_add() is implemented as a macro, so that the fsetup(), ftest() and -fteardown() callbacks can expect a @Fixture pointer as first argument in -a type safe manner. +fteardown() callbacks can expect a @Fixture pointer as their first argument +in a type safe manner. They otherwise have type #GTestFixtureFunc. Since: 2.16 @@ -43852,15 +45696,15 @@ Since: 2.16 </description> <parameters> <parameter name="testpath"> -<parameter_description> /-separated test case path name for the test. +<parameter_description> /-separated test case path name for the test. </parameter_description> </parameter> <parameter name="test_data"> -<parameter_description> Test data argument for the test function. +<parameter_description> Test data argument for the test function. </parameter_description> </parameter> <parameter name="test_func"> -<parameter_description> The test function to invoke for this test. +<parameter_description> The test function to invoke for this test. </parameter_description> </parameter> </parameters> @@ -43912,7 +45756,7 @@ Since: 2.16 </description> <parameters> <parameter name="testpath"> -<parameter_description> /-separated test case path name for the test. +<parameter_description> /-separated test case path name for the test. </parameter_description> </parameter> <parameter name="test_func"> @@ -44036,14 +45880,14 @@ Since: 2.38 Create a new #GTestCase, named @test_name, this API is fairly low level, calling g_test_add() or g_test_add_func() is preferable. When this test is executed, a fixture structure of size @data_size -will be allocated and filled with 0s. Then @data_setup is called -to initialize the fixture. After fixture setup, the actual test -function @data_test is called. Once the test run completed, the -fixture structure is torn down by calling @data_teardown and -after that the memory is released. +will be automatically allocated and filled with zeros. Then @data_setup is +called to initialize the fixture. After fixture setup, the actual test +function @data_test is called. Once the test run completes, the +fixture structure is torn down by calling @data_teardown and +after that the memory is automatically released by the test framework. Splitting up a test run into fixture setup, test function and -fixture teardown is most usful if the same fixture is used for +fixture teardown is most useful if the same fixture is used for multiple tests. In this cases, g_test_create_case() will be called with the same fixture, but varying @test_name and @data_test arguments. @@ -44065,11 +45909,11 @@ Since: 2.16 </parameter_description> </parameter> <parameter name="data_setup"> -<parameter_description> the function to set up the fixture data +<parameter_description> the function to set up the fixture data </parameter_description> </parameter> <parameter name="data_test"> -<parameter_description> the actual test function +<parameter_description> the actual test function </parameter_description> </parameter> <parameter name="data_teardown"> @@ -45641,6 +47485,29 @@ Returns the number of currently unused threads. </return> </function> +<function name="g_thread_pool_move_to_front"> +<description> +Moves the item to the front of the queue of unprocessed +items, so that it will be processed next. + +Since: 2.46 + +</description> +<parameters> +<parameter name="pool"> +<parameter_description> a #GThreadPool +</parameter_description> +</parameter> +<parameter name="data"> +<parameter_description> an unprocessed item in the pool +</parameter_description> +</parameter> +</parameters> +<return> %TRUE if the item was found and moved + +</return> +</function> + <function name="g_thread_pool_new"> <description> This function creates a new thread pool. @@ -45668,7 +47535,7 @@ global pool. @error can be %NULL to ignore errors, or non-%NULL to report errors. An error can only occur when @exclusive is set to %TRUE and not all @max_threads threads could be created. -See #GThreadError for possible errors that may occurr. +See #GThreadError for possible errors that may occur. Note, even in case of error a valid #GThreadPool is returned. @@ -45910,7 +47777,7 @@ Since: 2.32 <function name="g_thread_self"> <description> -This functions returns the #GThread corresponding to the +This function returns the #GThread corresponding to the current thread. Note that this function does not increase the reference count of the returned struct. @@ -46454,8 +48321,10 @@ g_timeout_add_seconds() function; this function allows for more optimizations and more efficient system power usage. This internally creates a main loop source using g_timeout_source_new() -and attaches it to the main loop context using g_source_attach(). You can -do these steps manually if you need greater control. +and attaches it to the global #GMainContext using g_source_attach(), so +the callback will be invoked in whichever thread is running that main +context. You can do these steps manually if you need greater control or to +use a custom main context. The interval given is in terms of monotonic time, not wall clock time. See g_get_monotonic_time(). @@ -46497,8 +48366,10 @@ timeout is recalculated based on the current time and the given interval (it does not try to 'catch up' time lost in delays). This internally creates a main loop source using g_timeout_source_new() -and attaches it to the main loop context using g_source_attach(). You can -do these steps manually if you need greater control. +and attaches it to the global #GMainContext using g_source_attach(), so +the callback will be invoked in whichever thread is running that main +context. You can do these steps manually if you need greater control or to +use a custom main context. The interval given in terms of monotonic time, not wall clock time. See g_get_monotonic_time(). @@ -47447,7 +49318,9 @@ Since: 2.8 <description> Attempts to realloc @mem to a new size, @n_bytes, and returns %NULL on failure. Contrast with g_realloc(), which aborts the program -on failure. If @mem is %NULL, behaves the same as g_try_malloc(). +on failure. + +If @mem is %NULL, behaves the same as g_try_malloc(). </description> @@ -48182,6 +50055,28 @@ or 0 if the type system ran out of fundamental type IDs </return> </function> +<function name="g_type_get_instance_count"> +<description> +Returns the number of instances allocated of the particular type; +this is only available if GLib is built with debugging support and +the instance_count debug flag is set (by setting the GOBJECT_DEBUG +variable to include instance-count). + +Since: 2.44 + +</description> +<parameters> +<parameter name="type"> +<parameter_description> a #GType +</parameter_description> +</parameter> +</parameters> +<return> the number of instances allocated of the given type; +if instance counts are not available, returns 0. + +</return> +</function> + <function name="g_type_get_plugin"> <description> Returns the #GTypePlugin structure for @type. @@ -53777,7 +55672,7 @@ Since: 2.30 Similar to g_variant_get_string() except that instead of returning a constant string, the string is duplicated. -The string will always be utf8 encoded. +The string will always be UTF-8 encoded. The return value must be freed using g_free(). @@ -53794,7 +55689,7 @@ Since: 2.24 </parameter_description> </parameter> </parameters> -<return> a newly allocated string, utf8 encoded +<return> a newly allocated string, UTF-8 encoded </return> </function> @@ -54205,17 +56100,6 @@ the fixed array </return> </function> -<function name="g_variant_get_gtype"> -<description> -Since: 2.24 -Deprecated: 2.26 - -</description> -<parameters> -</parameters> -<return></return> -</function> - <function name="g_variant_get_handle"> <description> Returns the 32-bit signed integer value of @value. @@ -54421,7 +56305,7 @@ Returns the string value of a #GVariant instance with a string type. This includes the types %G_VARIANT_TYPE_STRING, %G_VARIANT_TYPE_OBJECT_PATH and %G_VARIANT_TYPE_SIGNATURE. -The string will always be utf8 encoded. +The string will always be UTF-8 encoded. If @length is non-%NULL then the length of the string (in bytes) is returned there. For trusted values, this information is already @@ -54446,7 +56330,7 @@ to store the length </parameter_description> </parameter> </parameters> -<return> the constant string, utf8 encoded +<return> the constant string, UTF-8 encoded </return> </function> @@ -55388,7 +57272,7 @@ Since: 2.24 <description> Creates an array-of-bytes #GVariant with the contents of @string. This function is just like g_variant_new_string() except that the -string need not be valid utf8. +string need not be valid UTF-8. The nul terminator character at the end of the string is stored in the array. @@ -55908,14 +57792,14 @@ Since: 2.24 <description> Creates a string #GVariant with the contents of @string. -@string must be valid utf8. +@string must be valid UTF-8. Since: 2.24 </description> <parameters> <parameter name="string"> -<parameter_description> a normal utf8 nul-terminated string +<parameter_description> a normal UTF-8 nul-terminated string </parameter_description> </parameter> </parameters> @@ -55953,7 +57837,7 @@ Since: 2.24 <description> Creates a string #GVariant with the contents of @string. -@string must be valid utf8. +@string must be valid UTF-8. This function consumes @string. g_free() will be called on @string when it is no longer required. @@ -55967,7 +57851,7 @@ Since: 2.38 </description> <parameters> <parameter name="string"> -<parameter_description> a normal utf8 nul-terminated string +<parameter_description> a normal UTF-8 nul-terminated string </parameter_description> </parameter> </parameters> @@ -56169,7 +58053,8 @@ errors (in the case that the type would have been ambiguous, such as with empty arrays). In the event that the parsing is successful, the resulting #GVariant -is returned. +is returned. It is never floating, and must be freed with +g_variant_unref(). In case of any error, %NULL will be returned. If @error is non-%NULL then it will be set to reflect the error that occurred. @@ -56201,7 +58086,7 @@ produced by g_variant_print()". </parameter_description> </parameter> </parameters> -<return> a reference to a #GVariant, or %NULL +<return> a non-floating reference to a #GVariant, or %NULL </return> </function> @@ -57578,6 +59463,48 @@ Since: 2.32 <return></return> </function> +<function name="g_win32_check_windows_version"> +<description> +Returns whether the version of the Windows operating system the +code is running on is at least the specified major, minor and +service pack versions. See MSDN documentation for the Operating +System Version. Software that needs even more detailed version and +feature information should use the Win32 API VerifyVersionInfo() +directly. + +Successive calls of this function can be used for enabling or +disabling features at run-time for a range of Windows versions, +as per the VerifyVersionInfo() API documentation. + +Since: 2.44 + +</description> +<parameters> +<parameter name="major"> +<parameter_description> major version of Windows +</parameter_description> +</parameter> +<parameter name="minor"> +<parameter_description> minor version of Windows +</parameter_description> +</parameter> +<parameter name="spver"> +<parameter_description> Windows Service Pack Level, 0 if none +</parameter_description> +</parameter> +<parameter name="os_type"> +<parameter_description> Type of Windows OS +</parameter_description> +</parameter> +</parameters> +<return> %TRUE if the Windows Version is the same or greater than +the specified major, minor and service pack versions, and +whether the running Windows is a workstation or server edition +of Windows, if specifically specified. + +</return> +</function> + <function name="g_win32_error_message"> <description> Translate a Win32 error code (as returned by GetLastError() or @@ -57788,17 +59715,14 @@ freed with g_free() when no longer needed. If something goes wrong, <function name="g_win32_get_windows_version"> <description> -Returns version information for the Windows operating system the -code is running on. See MSDN documentation for the GetVersion() -function. To summarize, the most significant bit is one on Win9x, -and zero on NT-based systems. Since version 2.14, GLib works only -on NT-based systems, so checking whether your are running on Win9x -in your own software is moot. The least significant byte is 4 on -Windows NT 4, and 5 on Windows XP. Software that needs really -detailed version and feature information should use Win32 API like -GetVersionEx() and VerifyVersionInfo(). +This function is deprecated. Use +g_win32_check_windows_version() instead. -Since: 2.6 +Deprecated: 2.44: Be aware that for Windows 8.1 and Windows Server +2012 R2 and later, this will return 62 unless the application is +manifested for Windows 8.1/Windows Server 2012 R2, for example. +MSDN stated that GetVersion(), which is used here, is subject to +further change or removal after Windows 8.1. </description> <parameters> @@ -58274,7 +60198,7 @@ Values of this type can range from #G_MINSSIZE to #G_MAXSSIZE. To print or scan values of this type, use -%G_GSIZE_MODIFIER and/or %G_GSSIZE_FORMAT. +%G_GSSIZE_MODIFIER and/or %G_GSSIZE_FORMAT. </description> <parameters> |