diff options
author | Kjell Ahlstedt <kjellahlstedt@gmail.com> | 2022-04-07 15:19:40 +0200 |
---|---|---|
committer | Kjell Ahlstedt <kjellahlstedt@gmail.com> | 2022-04-07 15:19:40 +0200 |
commit | 645947b3b8443995b58e3b5db1f953a80ec84d74 (patch) | |
tree | 36efae7be44ed2a9ed6655c79f1c0bd46b4b0b9c | |
parent | a5aed6d79b650c6572ce21b9672c0e91831bead8 (diff) | |
download | glibmm-645947b3b8443995b58e3b5db1f953a80ec84d74.tar.gz |
Glib, Gio: Regenerate docs.xml and .defs files
using gtk files from glib 2.72.0.
And update gio/src/gio_signals.defs.patch.
-rw-r--r-- | gio/src/gio_docs.xml | 850 | ||||
-rw-r--r-- | gio/src/gio_enums.defs | 14 | ||||
-rw-r--r-- | gio/src/gio_methods.defs | 118 | ||||
-rw-r--r-- | gio/src/gio_signals.defs | 22 | ||||
-rw-r--r-- | gio/src/gio_signals.defs.patch | 11 | ||||
-rw-r--r-- | glib/src/glib_docs.xml | 1317 | ||||
-rw-r--r-- | glib/src/glib_enums.defs | 34 | ||||
-rw-r--r-- | glib/src/glib_functions.defs | 85 | ||||
-rw-r--r-- | glib/src/gobject_functions.defs | 175 |
9 files changed, 2296 insertions, 330 deletions
diff --git a/gio/src/gio_docs.xml b/gio/src/gio_docs.xml index 3bc7c30f..1e157a3a 100644 --- a/gio/src/gio_docs.xml +++ b/gio/src/gio_docs.xml @@ -181,7 +181,7 @@ or removed applications). <signal name="GAppLaunchContext::launch-failed"> <description> -The ::launch-failed signal is emitted when a #GAppInfo launch +The #GAppLaunchContext::launch-failed signal is emitted when a #GAppInfo launch fails. The startup notification id is provided, so that the launcher can cancel the startup notification. @@ -201,13 +201,54 @@ Since: 2.36 <return></return> </signal> +<signal name="GAppLaunchContext::launch-started"> +<description> +The #GAppLaunchContext::launch-started signal is emitted when a #GAppInfo is +about to be launched. If non-null the @platform_data is an +GVariant dictionary mapping strings to variants (ie `a{sv}`), which +contains additional, platform-specific data about this launch. On +UNIX, at least the `startup-notification-id` keys will be +present. + +The value of the `startup-notification-id` key (type `s`) is a startup +notification ID corresponding to the format from the [startup-notification +specification](https://specifications.freedesktop.org/startup-notification-spec/startup-notification-0.1.txt). +It allows tracking the progress of the launchee through startup. + +It is guaranteed that this signal is followed by either a #GAppLaunchContext::launched or +#GAppLaunchContext::launch-failed signal. + +Since: 2.72 + +</description> +<parameters> +<parameter name="context"> +<parameter_description> the object emitting the signal +</parameter_description> +</parameter> +<parameter name="info"> +<parameter_description> the #GAppInfo that is about to be launched +</parameter_description> +</parameter> +<parameter name="platform_data"> +<parameter_description> additional platform-specific data for this launch +</parameter_description> +</parameter> +</parameters> +<return></return> +</signal> + <signal name="GAppLaunchContext::launched"> <description> -The ::launched signal is emitted when a #GAppInfo is successfully +The #GAppLaunchContext::launched signal is emitted when a #GAppInfo is successfully launched. The @platform_data is an GVariant dictionary mapping -strings to variants (ie a{sv}), which contains additional, +strings to variants (ie `a{sv}`), which contains additional, platform-specific data about this launch. On UNIX, at least the -"pid" and "startup-notification-id" keys will be present. +`pid` and `startup-notification-id` keys will be present. + +Since 2.72 the `pid` may be 0 if the process id wasn't known (for +example if the process was launched via D-Bus). The `pid` may not be +set at all in subsequent releases. Since: 2.36 @@ -553,7 +594,7 @@ Since: 2.26 </parameter> <parameter name="G_BUS_NAME_OWNER_FLAGS_REPLACE"> <parameter_description> If another message bus connection owns the name and have -specified #G_BUS_NAME_OWNER_FLAGS_ALLOW_REPLACEMENT, then take the name from the other connection. +specified %G_BUS_NAME_OWNER_FLAGS_ALLOW_REPLACEMENT, then take the name from the other connection. </parameter_description> </parameter> <parameter name="G_BUS_NAME_OWNER_FLAGS_DO_NOT_QUEUE"> @@ -769,6 +810,10 @@ Since: 2.26 <parameter_description> The native credentials type is a `struct xucred`. Added in 2.66. </parameter_description> </parameter> +<parameter name="G_CREDENTIALS_TYPE_WIN32_PID"> +<parameter_description> The native credentials type is a PID `DWORD`. Added in 2.72. +</parameter_description> +</parameter> </parameters> </enum> @@ -2019,6 +2064,10 @@ Since: 2.26 <description> Emitted when a signal from the remote object and interface that @proxy is for, has been received. +Since 2.72 this signal supports detailed connections. You can connect to +the detailed signal `g-signal::x` in order to receive callbacks only when +signal `x` is received from the remote object. + Since: 2.26 </description> @@ -2196,6 +2245,12 @@ autostarted by a method call. This flag is only meaningful in proxies for well-k and only if %G_DBUS_PROXY_FLAGS_DO_NOT_AUTO_START is not also specified. </parameter_description> </parameter> +<parameter name="G_DBUS_PROXY_FLAGS_NO_MATCH_RULE"> +<parameter_description> Don't actually send the AddMatch D-Bus +call for this signal subscription. This gives you more control +over which match rules you add (but you must add them manually). (Since: 2.72) +</parameter_description> +</parameter> </parameters> </enum> @@ -2476,6 +2531,67 @@ across various machine architectures. </parameters> </enum> +<property name="GDebugController:debug-enabled"> +<description> +%TRUE if debug output should be exposed (for example by forwarding it to +the journal), %FALSE otherwise. + +Since: 2.72 + +</description> +</property> + +<signal name="GDebugControllerDBus::authorize"> +<description> +Emitted when a D-Bus peer is trying to change the debug settings and used +to determine if that is authorized. + +This signal is emitted in a dedicated worker thread, so handlers are +allowed to perform blocking I/O. This means that, for example, it is +appropriate to call `polkit_authority_check_authorization_sync()` to check +authorization using polkit. + +If %FALSE is returned then no further handlers are run and the request to +change the debug settings is rejected. + +Otherwise, if %TRUE is returned, signal emission continues. If no handlers +return %FALSE, then the debug settings are allowed to be changed. + +Signal handlers must not modify @invocation, or cause it to return a value. + +The default class handler just returns %TRUE. + +Since: 2.72 + +</description> +<parameters> +<parameter name="controller"> +<parameter_description> The #GDebugControllerDBus emitting the signal. +</parameter_description> +</parameter> +<parameter name="invocation"> +<parameter_description> A #GDBusMethodInvocation. +</parameter_description> +</parameter> +</parameters> +<return> %TRUE if the call is authorized, %FALSE otherwise. + +</return> +</signal> + +<property name="GDebugControllerDBus:connection"> +<description> +The D-Bus connection to expose the debugging interface on. + +Typically this will be the same connection (to the system or session bus) +which the rest of the application or service’s D-Bus objects are registered +on. + +Since: 2.72 + +</description> +</property> + <property name="GDesktopAppInfo:filename"> <description> The origin filename of this #GDesktopAppInfo @@ -2663,6 +2779,15 @@ certificate to be accepted despite @errors, return %TRUE from the signal handler. Otherwise, if no handler accepts the certificate, the handshake will fail with %G_TLS_ERROR_BAD_CERTIFICATE. +GLib guarantees that if certificate verification fails, this signal +will be emitted with at least one error will be set in @errors, but +it does not guarantee that all possible errors will be set. +Accordingly, you may not safely decide to ignore any particular +type of error. For example, it would be incorrect to ignore +%G_TLS_CERTIFICATE_EXPIRED if you want to allow expired +certificates, because this could potentially be the only error flag +set even if other problems exist with the certificate. + For a server-side connection, @peer_cert is the certificate presented by the client, if this was requested via the server's #GDtlsServerConnection:authentication_mode. On the server side, @@ -2756,6 +2881,19 @@ The certificate database to use when verifying this TLS connection. If no certificate database is set, then the default database will be used. See g_tls_backend_get_default_database(). +When using a non-default database, #GDtlsConnection must fall back to using +the #GTlsDatabase to perform certificate verification using +g_tls_database_verify_chain(), which means certificate verification will +not be able to make use of TLS session context. This may be less secure. +For example, if you create your own #GTlsDatabase that just wraps the +default #GTlsDatabase, you might expect that you have not changed anything, +but this is not true because you may have altered the behavior of +#GDtlsConnection by causing it to use g_tls_database_verify_chain(). See the +documentation of g_tls_database_verify_chain() for more details on specific +security checks that may not be performed. Accordingly, setting a +non-default database is discouraged except for specialty applications with +unusual security requirements. + Since: 2.48 </description> @@ -2805,6 +2943,14 @@ it may not be if #GDtlsClientConnection:validation-flags is not #GDtlsConnection::accept-certificate overrode the default behavior. +GLib guarantees that if certificate verification fails, at least +one error will be set, but it does not guarantee that all possible +errors will be set. Accordingly, you may not safely decide to +ignore any particular type of error. For example, it would be +incorrect to mask %G_TLS_CERTIFICATE_EXPIRED if you want to allow +expired certificates, because this could potentially be the only +error flag set even if other problems exist with the certificate. + Since: 2.48 </description> @@ -3105,7 +3251,7 @@ pair. This is exactly how the events will be reported in the case that the %G_FILE_MONITOR_WATCH_MOVES flag is not in use. If using the deprecated flag %G_FILE_MONITOR_SEND_MOVED flag and @event_type is -#G_FILE_MONITOR_EVENT_MOVED, @file will be set to a #GFile containing the +%G_FILE_MONITOR_EVENT_MOVED, @file will be set to a #GFile containing the old path, and @other_file will be set to a #GFile containing the new path. In all the other cases, @other_file will be set to #NULL. @@ -3309,7 +3455,7 @@ Emitted when the file name completion information comes available. <description> Indicates a hint from the file system whether files should be previewed in a file manager. Returned as the value of the key -#G_FILE_ATTRIBUTE_FILESYSTEM_USE_PREVIEW. +%G_FILE_ATTRIBUTE_FILESYSTEM_USE_PREVIEW. </description> <parameters> @@ -3344,7 +3490,7 @@ if (g_error_matches (error, G_IO_ERROR, G_IO_ERROR_FAILED)) } ]| but should instead treat all unrecognized error codes the same as -#G_IO_ERROR_FAILED. +%G_IO_ERROR_FAILED. See also #GPollableReturn for a cheaper way of returning %G_IO_ERROR_WOULD_BLOCK to callers without allocating a #GError. @@ -3764,7 +3910,7 @@ This signal is emitted whenever items were added to or removed from @list. At @position, @removed items were removed and @added items were added in their place. -Note: If @removed != @added, the positions of all later items +Note: If `removed != added`, the positions of all later items in the model change. Since: 2.44 @@ -5105,7 +5251,7 @@ It is an error to use this flag if the property is not readable. </parameter_description> </parameter> <parameter name="G_SETTINGS_BIND_GET_NO_CHANGES"> -<parameter_description> When set in addition to #G_SETTINGS_BIND_GET, set the #GObject property +<parameter_description> When set in addition to %G_SETTINGS_BIND_GET, set the #GObject property value initially from the setting, but do not listen for changes of the setting </parameter_description> </parameter> @@ -5451,6 +5597,30 @@ Since: 2.36 </description> </property> +<property name="GSocketClient:tls-validation-flags"> +<description> +The TLS validation flags used when creating TLS connections. The +default value is %G_TLS_CERTIFICATE_VALIDATE_ALL. + +GLib guarantees that if certificate verification fails, at least one +flag will be set, but it does not guarantee that all possible flags +will be set. Accordingly, you may not safely decide to ignore any +particular type of error. For example, it would be incorrect to mask +%G_TLS_CERTIFICATE_EXPIRED if you want to allow expired certificates, +because this could potentially be the only error flag set even if +other problems exist with the certificate. Therefore, there is no +safe way to use this property. This is not a horrible problem, +though, because you should not be attempting to ignore validation +errors anyway. If you really must ignore TLS certificate errors, +connect to the #GSocketClient::event signal, wait for it to be +emitted with %G_SOCKET_CLIENT_TLS_HANDSHAKING, and use that to +connect to #GTlsConnection::accept-certificate. + +Deprecated: 2.72: Do not attempt to ignore validation errors. + +</description> +</property> + <enum name="GSocketClientEvent"> <description> Describes an event occurring on a #GSocketClient. See the @@ -5804,6 +5974,12 @@ been explicitly marked as close-on-exec. This flag has no effect over the "standard" file descriptors (stdin, stdout, stderr). </parameter_description> </parameter> +<parameter name="G_SUBPROCESS_FLAGS_SEARCH_PATH_FROM_ENVP"> +<parameter_description> if path searching is +needed when spawning the subprocess, use the `PATH` in the launcher +environment. (Since: 2.72) +</parameter_description> +</parameter> </parameters> </enum> @@ -6029,6 +6205,15 @@ Since: 2.70 </description> </property> +<property name="GTlsCertificate:password"> +<description> +An optional password used when constructed with GTlsCertificate:pkcs12-data. + +Since: 2.72 + +</description> +</property> + <property name="GTlsCertificate:pkcs11-uri"> <description> A URI referencing the [PKCS \#11](https://docs.oasis-open.org/pkcs11/pkcs11-base/v3.0/os/pkcs11-base-v3.0-os.html) @@ -6042,6 +6227,17 @@ Since: 2.68 </description> </property> +<property name="GTlsCertificate:pkcs12-data"> +<description> +The PKCS #12 formatted data used to construct the object. + +See also: g_tls_certificate_new_from_pkcs12() + +Since: 2.72 + +</description> +</property> + <property name="GTlsCertificate:private-key"> <description> The DER (binary) encoded representation of the certificate's @@ -6116,10 +6312,16 @@ Since: 2.70 <enum name="GTlsCertificateFlags"> <description> A set of flags describing TLS certification validation. This can be -used to set which validation steps to perform (eg, with -g_tls_client_connection_set_validation_flags()), or to describe why -a particular certificate was rejected (eg, in -#GTlsConnection::accept-certificate). +used to describe why a particular certificate was rejected (for +example, in #GTlsConnection::accept-certificate). + +GLib guarantees that if certificate verification fails, at least one +flag will be set, but it does not guarantee that all possible flags +will be set. Accordingly, you may not safely decide to ignore any +particular type of error. For example, it would be incorrect to mask +%G_TLS_CERTIFICATE_EXPIRED if you want to allow expired certificates, +because this could potentially be the only error flag set even if +other problems exist with the certificate. Since: 2.28 @@ -6309,8 +6511,22 @@ a server. Server certificates that fail to validate in any of the ways indicated here will be rejected unless the application overrides the default via #GTlsConnection::accept-certificate. +GLib guarantees that if certificate verification fails, at least one +flag will be set, but it does not guarantee that all possible flags +will be set. Accordingly, you may not safely decide to ignore any +particular type of error. For example, it would be incorrect to mask +%G_TLS_CERTIFICATE_EXPIRED if you want to allow expired certificates, +because this could potentially be the only error flag set even if +other problems exist with the certificate. Therefore, there is no +safe way to use this property. This is not a horrible problem, +though, because you should not be attempting to ignore validation +errors anyway. If you really must ignore TLS certificate errors, +connect to #GTlsConnection::accept-certificate. + Since: 2.28 +Deprecated: 2.72: Do not attempt to ignore validation errors. + </description> </property> @@ -6328,6 +6544,15 @@ certificate to be accepted despite @errors, return %TRUE from the signal handler. Otherwise, if no handler accepts the certificate, the handshake will fail with %G_TLS_ERROR_BAD_CERTIFICATE. +GLib guarantees that if certificate verification fails, this signal +will be emitted with at least one error will be set in @errors, but +it does not guarantee that all possible errors will be set. +Accordingly, you may not safely decide to ignore any particular +type of error. For example, it would be incorrect to ignore +%G_TLS_CERTIFICATE_EXPIRED if you want to allow expired +certificates, because this could potentially be the only error flag +set even if other problems exist with the certificate. + For a server-side connection, @peer_cert is the certificate presented by the client, if this was requested via the server's #GTlsServerConnection:authentication_mode. On the server side, @@ -6424,6 +6649,19 @@ The certificate database to use when verifying this TLS connection. If no certificate database is set, then the default database will be used. See g_tls_backend_get_default_database(). +When using a non-default database, #GTlsConnection must fall back to using +the #GTlsDatabase to perform certificate verification using +g_tls_database_verify_chain(), which means certificate verification will +not be able to make use of TLS session context. This may be less secure. +For example, if you create your own #GTlsDatabase that just wraps the +default #GTlsDatabase, you might expect that you have not changed anything, +but this is not true because you may have altered the behavior of +#GTlsConnection by causing it to use g_tls_database_verify_chain(). See the +documentation of g_tls_database_verify_chain() for more details on specific +security checks that may not be performed. Accordingly, setting a +non-default database is discouraged except for specialty applications with +unusual security requirements. + Since: 2.30 </description> @@ -6473,6 +6711,14 @@ it may not be if #GTlsClientConnection:validation-flags is not #GTlsConnection::accept-certificate overrode the default behavior. +GLib guarantees that if certificate verification fails, at least +one error will be set, but it does not guarantee that all possible +errors will be set. Accordingly, you may not safely decide to +ignore any particular type of error. For example, it would be +incorrect to mask %G_TLS_CERTIFICATE_EXPIRED if you want to allow +expired certificates, because this could potentially be the only +error flag set even if other problems exist with the certificate. + Since: 2.28 </description> @@ -6607,6 +6853,11 @@ because the client sent the fallback SCSV, indicating a protocol downgrade attack. Since: 2.60 </parameter_description> </parameter> +<parameter name="G_TLS_ERROR_BAD_CERTIFICATE_PASSWORD"> +<parameter_description> The certificate failed +to load because a password was incorrect. Since: 2.72 +</parameter_description> +</parameter> </parameters> </enum> @@ -11636,7 +11887,9 @@ The returned object is a singleton, that is, shared with other callers of g_bus_get() and g_bus_get_sync() for @bus_type. In the event that you need a private message bus connection, use g_dbus_address_get_for_bus_sync() and -g_dbus_connection_new_for_address(). +g_dbus_connection_new_for_address() with +G_DBUS_CONNECTION_FLAGS_AUTHENTICATION_CLIENT and +G_DBUS_CONNECTION_FLAGS_MESSAGE_BUS_CONNECTION flags. Note that the returned #GDBusConnection object will (usually) have the #GDBusConnection:exit-on-close property set to %TRUE. @@ -11675,7 +11928,9 @@ The returned object is a singleton, that is, shared with other callers of g_bus_get() and g_bus_get_sync() for @bus_type. In the event that you need a private message bus connection, use g_dbus_address_get_for_bus_sync() and -g_dbus_connection_new_for_address(). +g_dbus_connection_new_for_address() with +G_DBUS_CONNECTION_FLAGS_AUTHENTICATION_CLIENT and +G_DBUS_CONNECTION_FLAGS_MESSAGE_BUS_CONNECTION flags. Note that the returned #GDBusConnection object will (usually) have the #GDBusConnection:exit-on-close property set to %TRUE. @@ -12819,7 +13074,7 @@ on the other argument. </description> <parameters> <parameter name="filename"> -<parameter_description> a string, or %NULL +<parameter_description> a path, or %NULL </parameter_description> </parameter> <parameter name="data"> @@ -13254,8 +13509,7 @@ method is only available on UNIX platforms. This operation can fail if #GCredentials is not supported on the OS or if the native credentials type does not contain information -about the UNIX process ID (for example this is the case for -%G_CREDENTIALS_TYPE_APPLE_XUCRED). +about the UNIX process ID. Since: 2.36 @@ -16477,7 +16731,7 @@ It is considered a programming error if the #GVariant of incorrect type. If an existing callback is already registered at @object_path and -@interface_name, then @error is set to #G_IO_ERROR_EXISTS. +@interface_name, then @error is set to %G_IO_ERROR_EXISTS. GDBus automatically implements the standard D-Bus interfaces org.freedesktop.DBus.Properties, org.freedesktop.DBus.Introspectable @@ -16585,7 +16839,7 @@ by @object_path. When handling remote calls into any node in the subtree, first the @enumerate function is used to check if the node exists. If the node exists -or the #G_DBUS_SUBTREE_FLAGS_DISPATCH_TO_UNENUMERATED_NODES flag is set +or the %G_DBUS_SUBTREE_FLAGS_DISPATCH_TO_UNENUMERATED_NODES flag is set the @introspection function is used to check if the node supports the requested method. If so, the @dispatch function is used to determine where to dispatch the call. The collected #GDBusInterfaceVTable and @@ -16597,7 +16851,7 @@ All calls into user-provided code will be invoked in the of the thread you are calling this method from. If an existing subtree is already registered at @object_path or -then @error is set to #G_IO_ERROR_EXISTS. +then @error is set to %G_IO_ERROR_EXISTS. Note that it is valid to register regular objects (using g_dbus_connection_register_object()) in a subtree registered with @@ -17296,7 +17550,7 @@ create the #GError. Also, @dbus_error_name is added to the error message such that it can be recovered with g_dbus_error_get_remote_error(). Otherwise, a #GError with the error code %G_IO_ERROR_DBUS_ERROR -in the #G_IO_ERROR error domain is returned. Also, @dbus_error_name is +in the %G_IO_ERROR error domain is returned. Also, @dbus_error_name is added to the error message such that it can be recovered with g_dbus_error_get_remote_error(). @@ -17586,23 +17840,23 @@ parameter. The conversion is using the following rules: -- #G_TYPE_STRING: 's', 'o', 'g' or 'ay' -- #G_TYPE_STRV: 'as', 'ao' or 'aay' -- #G_TYPE_BOOLEAN: 'b' -- #G_TYPE_UCHAR: 'y' -- #G_TYPE_INT: 'i', 'n' -- #G_TYPE_UINT: 'u', 'q' -- #G_TYPE_INT64 'x' -- #G_TYPE_UINT64: 't' -- #G_TYPE_DOUBLE: 'd' -- #G_TYPE_VARIANT: Any #GVariantType - -This can fail if e.g. @gvalue is of type #G_TYPE_STRING and @type -is ['i'][G-VARIANT-TYPE-INT32:CAPS]. It will also fail for any #GType -(including e.g. #G_TYPE_OBJECT and #G_TYPE_BOXED derived-types) not +- `G_TYPE_STRING`: 's', 'o', 'g' or 'ay' +- `G_TYPE_STRV`: 'as', 'ao' or 'aay' +- `G_TYPE_BOOLEAN`: 'b' +- `G_TYPE_UCHAR`: 'y' +- `G_TYPE_INT`: 'i', 'n' +- `G_TYPE_UINT`: 'u', 'q' +- `G_TYPE_INT64`: 'x' +- `G_TYPE_UINT64`: 't' +- `G_TYPE_DOUBLE`: 'd' +- `G_TYPE_VARIANT`: Any #GVariantType + +This can fail if e.g. @gvalue is of type %G_TYPE_STRING and @type +is 'i', i.e. %G_VARIANT_TYPE_INT32. It will also fail for any #GType +(including e.g. %G_TYPE_OBJECT and %G_TYPE_BOXED derived-types) not in the table above. -Note that if @gvalue is of type #G_TYPE_VARIANT and its value is +Note that if @gvalue is of type %G_TYPE_VARIANT and its value is %NULL, the empty #GVariant instance (never %NULL) for @type is returned (e.g. 0 for scalar types, the empty string for string types, '/' for object path types, the empty array for any array type and so on). @@ -20608,7 +20862,7 @@ with g_object_unref(). <function name="g_dbus_object_manager_get_object"> <description> -Gets the #GDBusObjectProxy at @object_path, if any. +Gets the #GDBusObject at @object_path, if any. Since: 2.30 @@ -22196,6 +22450,106 @@ from g_dbus_escape_object_path(). Free with g_free(). </return> </function> +<function name="g_debug_controller_dbus_new"> +<description> +Create a new #GDebugControllerDBus and synchronously initialize it. + +Initializing the object will export the debug object on @connection. The +object will remain registered until the last reference to the +#GDebugControllerDBus is dropped. + +Initialization may fail if registering the object on @connection fails. + +Since: 2.72 + +</description> +<parameters> +<parameter name="connection"> +<parameter_description> a #GDBusConnection to register the debug object on +</parameter_description> +</parameter> +<parameter name="cancellable"> +<parameter_description> a #GCancellable, or %NULL +</parameter_description> +</parameter> +<parameter name="error"> +<parameter_description> return location for a #GError, or %NULL +</parameter_description> +</parameter> +</parameters> +<return> a new #GDebugControllerDBus, or %NULL +on failure +</return> +</function> + +<function name="g_debug_controller_dbus_stop"> +<description> +Stop the debug controller, unregistering its object from the bus. + +Any pending method calls to the object will complete successfully, but new +ones will return an error. This method will block until all pending +#GDebugControllerDBus::authorize signals have been handled. This is expected +to not take long, as it will just be waiting for threads to join. If any +#GDebugControllerDBus::authorize signal handlers are still executing in other +threads, this will block until after they have returned. + +This method will be called automatically when the final reference to the +#GDebugControllerDBus is dropped. You may want to call it explicitly to know +when the controller has been fully removed from the bus, or to break +reference count cycles. + +Calling this method from within a #GDebugControllerDBus::authorize signal +handler will cause a deadlock and must not be done. + +Since: 2.72 + +</description> +<parameters> +<parameter name="self"> +<parameter_description> a #GDebugControllerDBus +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + +<function name="g_debug_controller_get_debug_enabled"> +<description> +Get the value of #GDebugController:debug-enabled. + +Since: 2.72 + +</description> +<parameters> +<parameter name="self"> +<parameter_description> a #GDebugController +</parameter_description> +</parameter> +</parameters> +<return> %TRUE if debug output should be exposed, %FALSE otherwise +</return> +</function> + +<function name="g_debug_controller_set_debug_enabled"> +<description> +Set the value of #GDebugController:debug-enabled. + +Since: 2.72 + +</description> +<parameters> +<parameter name="self"> +<parameter_description> a #GDebugController +</parameter_description> +</parameter> +<parameter name="debug_enabled"> +<parameter_description> %TRUE if debug output should be exposed, %FALSE otherwise +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_desktop_app_info_get_action_name"> <description> Gets the user-visible display name of the "additional application @@ -22388,7 +22742,7 @@ is not found <description> Gets the value of the NoDisplay key, which helps determine if the application info should be shown in menus. See -#G_KEY_FILE_DESKTOP_KEY_NO_DISPLAY and g_app_info_should_show(). +%G_KEY_FILE_DESKTOP_KEY_NO_DISPLAY and g_app_info_should_show(). Since: 2.30 @@ -23135,7 +23489,7 @@ Free the returned object with g_object_unref(). <description> Gets the identifier of the given kind for @drive. The only identifier currently available is -#G_DRIVE_IDENTIFIER_KIND_UNIX_DEVICE. +%G_DRIVE_IDENTIFIER_KIND_UNIX_DEVICE. </description> @@ -24237,6 +24591,9 @@ peer certificate validation will always set the client-side connections, unless that bit is not set in #GDtlsClientConnection:validation-flags). +There are nonintuitive security implications when using a non-default +database. See #GDtlsConnection:database for details. + Since: 2.48 </description> @@ -24672,7 +25029,7 @@ Gets an output stream for appending data to the file. If the file doesn't already exist it is created. By default files created are generally readable by everyone, -but if you pass #G_FILE_CREATE_PRIVATE in @flags the file +but if you pass %G_FILE_CREATE_PRIVATE in @flags the file will be made readable only to the current user, to the level that is supported on the target filesystem. @@ -25170,14 +25527,14 @@ or %NULL if an error occurs. Copies the file @source to the location specified by @destination. Can not handle recursive copies of directories. -If the flag #G_FILE_COPY_OVERWRITE is specified an already +If the flag %G_FILE_COPY_OVERWRITE is specified an already existing @destination file is overwritten. -If the flag #G_FILE_COPY_NOFOLLOW_SYMLINKS is specified then symlinks +If the flag %G_FILE_COPY_NOFOLLOW_SYMLINKS is specified then symlinks will be copied as symlinks, otherwise the target of the @source symlink will be copied. -If the flag #G_FILE_COPY_ALL_METADATA is specified then all the metadata +If the flag %G_FILE_COPY_ALL_METADATA is specified then all the metadata that is possible to copy is copied, not just the default subset (which, for instance, does not include the owner, see #GFileInfo). @@ -25194,7 +25551,7 @@ the total number of bytes copied during the operation. If the @source file does not exist, then the %G_IO_ERROR_NOT_FOUND error is returned, independent on the status of the @destination. -If #G_FILE_COPY_OVERWRITE is not specified and the target exists, then +If %G_FILE_COPY_OVERWRITE is not specified and the target exists, then the error %G_IO_ERROR_EXISTS is returned. If trying to overwrite a file over a directory, the %G_IO_ERROR_IS_DIRECTORY @@ -25202,7 +25559,7 @@ error is returned. If trying to overwrite a directory with a directory the %G_IO_ERROR_WOULD_MERGE error is returned. If the source is a directory and the target does not exist, or -#G_FILE_COPY_OVERWRITE is specified and the target is a file, then the +%G_FILE_COPY_OVERWRITE is specified and the target is a file, then the %G_IO_ERROR_WOULD_RECURSE error is returned. If you are interested in copying the #GFile object itself (not the on-disk @@ -25310,7 +25667,7 @@ Copies the file attributes from @source to @destination. Normally only a subset of the file attributes are copied, those that are copies in a normal file copy operation (which for instance does not include e.g. owner). However -if #G_FILE_COPY_ALL_METADATA is specified in @flags, then +if %G_FILE_COPY_ALL_METADATA is specified in @flags, then all the metadata that is possible to copy is copied. This is useful when implementing move by copy + delete source. @@ -25374,7 +25731,7 @@ Creates a new file and returns an output stream for writing to it. The file must not already exist. By default files created are generally readable by everyone, -but if you pass #G_FILE_CREATE_PRIVATE in @flags the file +but if you pass %G_FILE_CREATE_PRIVATE in @flags the file will be made readable only to the current user, to the level that is supported on the target filesystem. @@ -25493,7 +25850,7 @@ Creates a new file and returns a stream for reading and writing to it. The file must not already exist. By default files created are generally readable by everyone, -but if you pass #G_FILE_CREATE_PRIVATE in @flags the file +but if you pass %G_FILE_CREATE_PRIVATE in @flags the file will be made readable only to the current user, to the level that is supported on the target filesystem. @@ -25928,7 +26285,9 @@ The wildcard "*" means all attributes, and a wildcard like "standard::*" means all attributes in the standard namespace. An example attribute query be "standard::*,owner::user". The standard attributes are available as defines, like -#G_FILE_ATTRIBUTE_STANDARD_NAME. +%G_FILE_ATTRIBUTE_STANDARD_NAME. %G_FILE_ATTRIBUTE_STANDARD_NAME should +always be specified if you plan to call g_file_enumerator_get_child() or +g_file_enumerator_iterate() on the returned enumerator. If @cancellable is not %NULL, then the operation can be cancelled by triggering the cancellable object from another thread. If the @@ -26149,6 +26508,9 @@ Return a new #GFile which refers to the file named by @info in the source directory of @enumerator. This function is primarily intended to be used inside loops with g_file_enumerator_next_file(). +To use this, %G_FILE_ATTRIBUTE_STANDARD_NAME must have been listed in the +attributes list used when creating the #GFileEnumerator. + This is a convenience method that's equivalent to: |[<!-- language="C" --> gchar *name = g_file_info_get_name (info); @@ -29630,7 +29992,7 @@ used, otherwise a copy + delete fallback is used. The native implementation may support moving directories (for instance on moves inside the same filesystem), but the fallback code does not. -If the flag #G_FILE_COPY_OVERWRITE is specified an already +If the flag %G_FILE_COPY_OVERWRITE is specified an already existing @destination file is overwritten. If @cancellable is not %NULL, then the operation can be cancelled by @@ -29646,7 +30008,7 @@ transferred with the total number of bytes copied during the operation. If the @source file does not exist, then the %G_IO_ERROR_NOT_FOUND error is returned, independent on the status of the @destination. -If #G_FILE_COPY_OVERWRITE is not specified and the target exists, +If %G_FILE_COPY_OVERWRITE is not specified and the target exists, then the error %G_IO_ERROR_EXISTS is returned. If trying to overwrite a file over a directory, the %G_IO_ERROR_IS_DIRECTORY @@ -29654,7 +30016,7 @@ error is returned. If trying to overwrite a directory with a directory the %G_IO_ERROR_WOULD_MERGE error is returned. If the source is a directory and the target does not exist, or -#G_FILE_COPY_OVERWRITE is specified and the target is a file, then +%G_FILE_COPY_OVERWRITE is specified and the target is a file, then the %G_IO_ERROR_WOULD_RECURSE error may be returned (if the native move operation isn't available). @@ -29697,6 +30059,93 @@ the callback function </return> </function> +<function name="g_file_move_async"> +<description> +Asynchronously moves a file @source to the location of @destination. For details of the behaviour, see g_file_move(). + +If @progress_callback is not %NULL, then that function that will be called +just like in g_file_move(). The callback will run in the default main context +of the thread calling g_file_move_async() — the same context as @callback is +run in. + +When the operation is finished, @callback will be called. You can then call +g_file_move_finish() to get the result of the operation. + +Since: 2.72 + +</description> +<parameters> +<parameter name="source"> +<parameter_description> #GFile pointing to the source location +</parameter_description> +</parameter> +<parameter name="destination"> +<parameter_description> #GFile pointing to the destination location +</parameter_description> +</parameter> +<parameter name="flags"> +<parameter_description> set of #GFileCopyFlags +</parameter_description> +</parameter> +<parameter name="io_priority"> +<parameter_description> the [I/O priority][io-priority] of the request +</parameter_description> +</parameter> +<parameter name="cancellable"> +<parameter_description> optional #GCancellable object, +%NULL to ignore +</parameter_description> +</parameter> +<parameter name="progress_callback"> +<parameter_description> #GFileProgressCallback +function for updates +</parameter_description> +</parameter> +<parameter name="progress_callback_data"> +<parameter_description> gpointer to user data for +the callback function +</parameter_description> +</parameter> +<parameter name="callback"> +<parameter_description> a #GAsyncReadyCallback to call +when the request is satisfied +</parameter_description> +</parameter> +<parameter name="user_data"> +<parameter_description> the data to pass to callback function +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + +<function name="g_file_move_finish"> +<description> +Finishes an asynchronous file movement, started with +g_file_move_async(). + +Since: 2.72 + +</description> +<parameters> +<parameter name="file"> +<parameter_description> input source #GFile +</parameter_description> +</parameter> +<parameter name="result"> +<parameter_description> a #GAsyncResult +</parameter_description> +</parameter> +<parameter name="error"> +<parameter_description> a #GError, or %NULL +</parameter_description> +</parameter> +</parameters> +<return> %TRUE on successful file move, %FALSE otherwise. + +</return> +</function> + <function name="g_file_new_build_filename"> <description> Constructs a #GFile from a series of elements using the correct @@ -30145,7 +30594,7 @@ or %NULL if no such path exists. The returned string is owned by @file. <function name="g_file_poll_mountable"> <description> -Polls a file of type #G_FILE_TYPE_MOUNTABLE. +Polls a file of type %G_FILE_TYPE_MOUNTABLE. If @cancellable is not %NULL, then the operation can be cancelled by triggering the cancellable object from another thread. If the operation @@ -30370,7 +30819,7 @@ Since: 2.18 </parameter_description> </parameter> </parameters> -<return> The #GFileType of the file and #G_FILE_TYPE_UNKNOWN +<return> The #GFileType of the file and %G_FILE_TYPE_UNKNOWN if the file does not exist </return> @@ -30391,9 +30840,9 @@ attributes or attribute wildcards. The wildcard "*" means all attributes, and a wildcard like "filesystem::*" means all attributes in the filesystem namespace. The standard namespace for filesystem attributes is "filesystem". Common attributes of interest are -#G_FILE_ATTRIBUTE_FILESYSTEM_SIZE (the total size of the filesystem -in bytes), #G_FILE_ATTRIBUTE_FILESYSTEM_FREE (number of bytes available), -and #G_FILE_ATTRIBUTE_FILESYSTEM_TYPE (type of the filesystem). +%G_FILE_ATTRIBUTE_FILESYSTEM_SIZE (the total size of the filesystem +in bytes), %G_FILE_ATTRIBUTE_FILESYSTEM_FREE (number of bytes available), +and %G_FILE_ATTRIBUTE_FILESYSTEM_TYPE (type of the filesystem). If @cancellable is not %NULL, then the operation can be cancelled by triggering the cancellable object from another thread. If the @@ -30518,7 +30967,7 @@ The wildcard "*" means all attributes, and a wildcard like "standard::*" means all attributes in the standard namespace. An example attribute query be "standard::*,owner::user". The standard attributes are available as defines, like -#G_FILE_ATTRIBUTE_STANDARD_NAME. +%G_FILE_ATTRIBUTE_STANDARD_NAME. If @cancellable is not %NULL, then the operation can be cancelled by triggering the cancellable object from another thread. If the @@ -30527,7 +30976,7 @@ returned. For symlinks, normally the information about the target of the symlink is returned, rather than information about the symlink -itself. However if you pass #G_FILE_QUERY_INFO_NOFOLLOW_SYMLINKS +itself. However if you pass %G_FILE_QUERY_INFO_NOFOLLOW_SYMLINKS in @flags the information about the symlink itself will be returned. Also, for symlinks that point to non-existing files the information about the symlink itself will be returned. @@ -30815,7 +31264,7 @@ may write to a temporary file and then atomically rename over the destination when the stream is closed. By default files created are generally readable by everyone, -but if you pass #G_FILE_CREATE_PRIVATE in @flags the file +but if you pass %G_FILE_CREATE_PRIVATE in @flags the file will be made readable only to the current user, to the level that is supported on the target filesystem. @@ -31314,6 +31763,9 @@ Resolves a relative path for @file to an absolute path. This call does no blocking I/O. +If the @relative_path is an absolute path name, the resolution +is done absolutely (without taking @file path as base). + </description> <parameters> @@ -31326,9 +31778,7 @@ This call does no blocking I/O. </parameter_description> </parameter> </parameters> -<return> #GFile to the resolved path. -%NULL if @relative_path is %NULL or if @file is invalid. -Free the returned object with g_object_unref(). +<return> a #GFile for the resolved path. </return> </function> @@ -31764,7 +32214,7 @@ The display name is converted from UTF-8 to the correct encoding for the target filesystem if possible and the @file is renamed to this. If you want to implement a rename operation in the user interface the -edit name (#G_FILE_ATTRIBUTE_STANDARD_EDIT_NAME) should be used as the +edit name (%G_FILE_ATTRIBUTE_STANDARD_EDIT_NAME) should be used as the initial value in the rename widget, and then the result after editing should be passed to g_file_set_display_name(). @@ -31872,7 +32322,7 @@ Free the returned object with g_object_unref(). <function name="g_file_start_mountable"> <description> -Starts a file of type #G_FILE_TYPE_MOUNTABLE. +Starts a file of type %G_FILE_TYPE_MOUNTABLE. Using @start_operation, you can request callbacks when, for instance, passwords are needed during authentication. @@ -31948,7 +32398,7 @@ otherwise. <function name="g_file_stop_mountable"> <description> -Stops a file of type #G_FILE_TYPE_MOUNTABLE. +Stops a file of type %G_FILE_TYPE_MOUNTABLE. If @cancellable is not %NULL, then the operation can be cancelled by triggering the cancellable object from another thread. If the operation @@ -32216,7 +32666,7 @@ instead. <function name="g_file_unmount_mountable_with_operation"> <description> -Unmounts a file of type #G_FILE_TYPE_MOUNTABLE. +Unmounts a file of type %G_FILE_TYPE_MOUNTABLE. If @cancellable is not %NULL, then the operation can be cancelled by triggering the cancellable object from another thread. If the operation @@ -34337,7 +34787,7 @@ Gets the required type for @extension_point. </parameter> </parameters> <return> the #GType that all implementations must have, -or #G_TYPE_INVALID if the extension point has no required type +or %G_TYPE_INVALID if the extension point has no required type </return> </function> @@ -35247,11 +35697,15 @@ the same location. <function name="g_list_model_get_item"> <description> -Get the item at @position. If @position is greater than the number of -items in @list, %NULL is returned. +Get the item at @position. + +If @position is greater than the number of items in @list, %NULL is +returned. %NULL is never returned for an index that is smaller than the length -of the list. See g_list_model_get_n_items(). +of the list. + +See also: g_list_model_get_n_items() Since: 2.44 @@ -35273,9 +35727,11 @@ Since: 2.44 <function name="g_list_model_get_item_type"> <description> -Gets the type of the items in @list. All items returned from -g_list_model_get_type() are of that type or a subtype, or are an -implementation of that interface. +Gets the type of the items in @list. + +All items returned from g_list_model_get_item() are of the type +returned by this function, or a subtype, or if the type is an +interface, they are an implementation of that interface. The item type of a #GListModel can not change during the life of the model. @@ -35318,11 +35774,18 @@ Since: 2.44 <function name="g_list_model_get_object"> <description> -Get the item at @position. If @position is greater than the number of -items in @list, %NULL is returned. +Get the item at @position. + +If @position is greater than the number of items in @list, %NULL is +returned. %NULL is never returned for an index that is smaller than the length -of the list. See g_list_model_get_n_items(). +of the list. + +This function is meant to be used by language bindings in place +of g_list_model_get_item(). + +See also: g_list_model_get_n_items() Since: 2.44 @@ -42628,7 +43091,7 @@ for more details. <description> This differs from g_resolver_lookup_by_name() in that you can modify the lookup behavior with @flags. For example this can be used to limit -results with #G_RESOLVER_NAME_LOOKUP_FLAGS_IPV4_ONLY. +results with %G_RESOLVER_NAME_LOOKUP_FLAGS_IPV4_ONLY. Since: 2.60 @@ -44167,7 +44630,10 @@ Creates a child settings object which has a base path of @settings. The schema for the child settings object must have been declared -in the schema of @settings using a <child> element. +in the schema of @settings using a `<child>` element. + +The created child settings object will inherit the #GSettings:delay-apply +mode from @settings. Since: 2.26 @@ -44690,8 +45156,8 @@ with it. </parameter_description> </parameter> </parameters> -<return> a list of the children on -@settings, in no defined order +<return> a list of the children +on @settings, in no defined order </return> </function> @@ -44715,8 +45181,8 @@ Deprecated: 2.46: Use g_settings_schema_list_keys() instead. </parameter_description> </parameter> </parameters> -<return> a list of the keys on -@settings, in no defined order +<return> a list +of the keys on @settings, in no defined order </return> </function> @@ -44731,9 +45197,9 @@ Deprecated: 2.40: Use g_settings_schema_source_list_schemas() instead </description> <parameters> </parameters> -<return> a list of relocatable -#GSettings schemas that are available, in no defined order. The list must -not be modified or freed. +<return> a list of +relocatable #GSettings schemas that are available, in no defined order. +The list must not be modified or freed. </return> </function> @@ -44752,9 +45218,9 @@ of your whole loop. </description> <parameters> </parameters> -<return> a list of #GSettings -schemas that are available, in no defined order. The list must not be -modified or freed. +<return> a list of +#GSettings schemas that are available, in no defined order. The list +must not be modified or freed. </return> </function> @@ -45336,8 +45802,8 @@ Since: 2.44 </parameter_description> </parameter> </parameters> -<return> a list of the children on -@settings, in no defined order +<return> a list of +the children on @settings, in no defined order </return> </function> @@ -45359,8 +45825,8 @@ Since: 2.46 </parameter_description> </parameter> </parameters> -<return> a list of the keys on -@schema, in no defined order +<return> a list +of the keys on @schema, in no defined order </return> </function> @@ -46315,7 +46781,7 @@ Deprecated: 2.46: Use g_task_report_error(). </parameter_description> </parameter> <parameter name="domain"> -<parameter_description> a #GQuark containing the error domain (usually #G_IO_ERROR). +<parameter_description> a #GQuark containing the error domain (usually %G_IO_ERROR). </parameter_description> </parameter> <parameter name="code"> @@ -46805,7 +47271,7 @@ Deprecated: 2.46: Use #GTask and g_task_return_new_error() instead. </parameter_description> </parameter> <parameter name="domain"> -<parameter_description> a #GQuark (usually #G_IO_ERROR). +<parameter_description> a #GQuark (usually %G_IO_ERROR). </parameter_description> </parameter> <parameter name="code"> @@ -46838,7 +47304,7 @@ Deprecated: 2.46: Use #GTask and g_task_return_error() instead. </parameter_description> </parameter> <parameter name="domain"> -<parameter_description> a #GQuark (usually #G_IO_ERROR). +<parameter_description> a #GQuark (usually %G_IO_ERROR). </parameter_description> </parameter> <parameter name="code"> @@ -48127,8 +48593,14 @@ Since: 2.28 Gets the TLS validation flags used creating TLS connections via @client. +This function does not work as originally designed and is impossible +to use correctly. See #GSocketClient:tls-validation-flags for more +information. + Since: 2.28 +Deprecated: 2.72: Do not attempt to ignore validation errors. + </description> <parameters> <parameter name="client"> @@ -48378,8 +48850,14 @@ Since: 2.28 Sets the TLS validation flags used when creating TLS connections via @client. The default value is %G_TLS_CERTIFICATE_VALIDATE_ALL. +This function does not work as originally designed and is impossible +to use correctly. See #GSocketClient:tls-validation-flags for more +information. + Since: 2.28 +Deprecated: 2.72: Do not attempt to ignore validation errors. + </description> <parameters> <parameter name="client"> @@ -53668,7 +54146,7 @@ function <description> Sets @task's result to @result (by copying it) and completes the task. -If @result is %NULL then a #GValue of type #G_TYPE_POINTER +If @result is %NULL then a #GValue of type %G_TYPE_POINTER with a value of %NULL will be used for the result. This is a very generic low-level method intended primarily for use @@ -53802,7 +54280,8 @@ For example, ‘Open file’ or ‘Connect to network host’. It is used to set name of the #GSource used for idle completion of the task. This function may only be called before the @task is first used in a thread -other than the one it was constructed in. +other than the one it was constructed in. It is called automatically by +g_task_set_source_tag() if not called already. Since: 2.60 @@ -53900,13 +54379,19 @@ cancelled. <function name="g_task_set_source_tag"> <description> -Sets @task's source tag. You can use this to tag a task return +Sets @task's source tag. + +You can use this to tag a task return value with a particular pointer (usually a pointer to the function doing the tagging) and then later check it using g_task_get_source_tag() (or g_async_result_is_tagged()) in the task's "finish" function, to figure out if the response came from a particular place. +A macro wrapper around this function will automatically set the +task’s name to the string form of @source_tag if it’s not already +set, for convenience. + Since: 2.36 </description> @@ -54753,30 +55238,59 @@ and its contents when you are done with it. <function name="g_tls_certificate_new_from_file"> <description> -Creates a #GTlsCertificate from the PEM-encoded data in @file. The -returned certificate will be the first certificate found in @file. As -of GLib 2.44, if @file contains more certificates it will try to load -a certificate chain. All certificates will be verified in the order -found (top-level certificate should be the last one in the file) and -the #GTlsCertificate:issuer property of each certificate will be set -accordingly if the verification succeeds. If any certificate in the -chain cannot be verified, the first certificate in the file will -still be returned. +Creates a #GTlsCertificate from the data in @file. + +As of 2.72, if the filename ends in `.p12` or `.pfx` the data is loaded by +g_tls_certificate_new_from_pkcs12() otherwise it is loaded by +g_tls_certificate_new_from_pem(). See those functions for +exact details. If @file cannot be read or parsed, the function will return %NULL and -set @error. Otherwise, this behaves like -g_tls_certificate_new_from_pem(). +set @error. Since: 2.28 </description> <parameters> <parameter name="file"> -<parameter_description> file containing a PEM-encoded certificate to import +<parameter_description> file containing a certificate to import </parameter_description> </parameter> <parameter name="error"> -<parameter_description> #GError for error reporting, or %NULL to ignore. +<parameter_description> #GError for error reporting, or %NULL to ignore +</parameter_description> +</parameter> +</parameters> +<return> the new certificate, or %NULL on error + +</return> +</function> + +<function name="g_tls_certificate_new_from_file_with_password"> +<description> +Creates a #GTlsCertificate from the data in @file. + +If @file cannot be read or parsed, the function will return %NULL and +set @error. + +Any unknown file types will error with %G_IO_ERROR_NOT_SUPPORTED. +Currently only `.p12` and `.pfx` files are supported. +See g_tls_certificate_new_from_pkcs12() for more details. + +Since: 2.72 + +</description> +<parameters> +<parameter name="file"> +<parameter_description> file containing a certificate to import +</parameter_description> +</parameter> +<parameter name="password"> +<parameter_description> password for PKCS #12 files +</parameter_description> +</parameter> +<parameter name="error"> +<parameter_description> #GError for error reporting, or %NULL to ignore </parameter_description> </parameter> </parameters> @@ -54914,6 +55428,52 @@ Since: 2.68 </return> </function> +<function name="g_tls_certificate_new_from_pkcs12"> +<description> +Creates a #GTlsCertificate from the data in @data. It must contain +a certificate and matching private key. + +If extra certificates are included they will be verified as a chain +and the #GTlsCertificate:issuer property will be set. +All other data will be ignored. + +You can pass as single password for all of the data which will be +used both for the PKCS #12 container as well as encrypted +private keys. If decryption fails it will error with +%G_TLS_ERROR_BAD_CERTIFICATE_PASSWORD. + +This constructor requires support in the current #GTlsBackend. +If support is missing it will error with +%G_IO_ERROR_NOT_SUPPORTED. + +Other parsing failures will error with %G_TLS_ERROR_BAD_CERTIFICATE. + +Since: 2.72 + +</description> +<parameters> +<parameter name="data"> +<parameter_description> DER-encoded PKCS #12 format certificate data +</parameter_description> +</parameter> +<parameter name="length"> +<parameter_description> the length of @data +</parameter_description> +</parameter> +<parameter name="password"> +<parameter_description> optional password for encrypted certificate data +</parameter_description> +</parameter> +<parameter name="error"> +<parameter_description> #GError for error reporting, or %NULL to ignore. +</parameter_description> +</parameter> +</parameters> +<return> the new certificate, or %NULL if @data is invalid + +</return> +</function> + <function name="g_tls_certificate_verify"> <description> This verifies @cert and returns a set of #GTlsCertificateFlags @@ -54933,13 +55493,18 @@ in its chain) must be signed by it, or else @trusted_ca is %NULL, that bit will never be set in the return value. -(All other #GTlsCertificateFlags values will always be set or unset -as appropriate.) +GLib guarantees that if certificate verification fails, at least one +error will be set in the return value, but it does not guarantee +that all possible errors will be set. Accordingly, you may not safely +decide to ignore any particular type of error. For example, it would +be incorrect to mask %G_TLS_CERTIFICATE_EXPIRED if you want to allow +expired certificates, because this could potentially be the only +error flag set even if other problems exist with the certificate. Because TLS session context is not used, #GTlsCertificate may not perform as many checks on the certificates as #GTlsConnection would. -For example, certificate constraints cannot be honored, and some -revocation checks cannot be performed. The best way to verify TLS +For example, certificate constraints may not be honored, and +revocation checks may not be performed. The best way to verify TLS certificates used by a TLS connection is to let #GTlsConnection handle the verification. @@ -55097,8 +55662,14 @@ Deprecated: 2.56: SSL 3.0 is insecure. <description> Gets @conn's validation flags +This function does not work as originally designed and is impossible +to use correctly. See #GTlsClientConnection:validation-flags for more +information. + Since: 2.28 +Deprecated: 2.72: Do not attempt to ignore validation errors. + </description> <parameters> <parameter name="conn"> @@ -55204,8 +55775,14 @@ Sets @conn's validation flags, to override the default set of checks performed when validating a server certificate. By default, %G_TLS_CERTIFICATE_VALIDATE_ALL is used. +This function does not work as originally designed and is impossible +to use correctly. See #GTlsClientConnection:validation-flags for more +information. + Since: 2.28 +Deprecated: 2.72: Do not attempt to ignore validation errors. + </description> <parameters> <parameter name="conn"> @@ -55424,6 +56001,8 @@ Gets the errors associated with validating @conn's peer's certificate, after the handshake has completed or failed. (It is not set during the emission of #GTlsConnection::accept-certificate.) +See #GTlsConnection:peer-certificate-errors for more information. + Since: 2.28 </description> @@ -55717,6 +56296,9 @@ peer certificate validation will always set the client-side connections, unless that bit is not set in #GTlsClientConnection:validation-flags). +There are nonintuitive security implications when using a non-default +database. See #GTlsConnection:database for details. + Since: 2.30 </description> @@ -56260,7 +56842,7 @@ of a TLS session. certificate in the chain by its #GTlsCertificate:issuer property. @purpose describes the purpose (or usage) for which the certificate -is being used. Typically @purpose will be set to #G_TLS_DATABASE_PURPOSE_AUTHENTICATE_SERVER +is being used. Typically @purpose will be set to %G_TLS_DATABASE_PURPOSE_AUTHENTICATE_SERVER which means that the certificate is being used to authenticate a server (and we are acting as the client). @@ -56276,13 +56858,21 @@ Currently there are no @flags, and %G_TLS_DATABASE_VERIFY_NONE should be used. If @chain is found to be valid, then the return value will be 0. If -@chain is found to be invalid, then the return value will indicate -the problems found. If the function is unable to determine whether -@chain is valid or not (eg, because @cancellable is triggered -before it completes) then the return value will be -%G_TLS_CERTIFICATE_GENERIC_ERROR and @error will be set -accordingly. @error is not set when @chain is successfully analyzed -but found to be invalid. +@chain is found to be invalid, then the return value will indicate at +least one problem found. If the function is unable to determine +whether @chain is valid (for example, because @cancellable is +triggered before it completes) then the return value will be +%G_TLS_CERTIFICATE_GENERIC_ERROR and @error will be set accordingly. +@error is not set when @chain is successfully analyzed but found to +be invalid. + +GLib guarantees that if certificate verification fails, at least one +error will be set in the return value, but it does not guarantee +that all possible errors will be set. Accordingly, you may not safely +decide to ignore any particular type of error. For example, it would +be incorrect to mask %G_TLS_CERTIFICATE_EXPIRED if you want to allow +expired certificates, because this could potentially be the only +error flag set even if other problems exist with the certificate. Prior to GLib 2.48, GLib's default TLS backend modified @chain to represent the certification path built by #GTlsDatabase during @@ -56294,14 +56884,14 @@ verification. Because TLS session context is not used, #GTlsDatabase may not perform as many checks on the certificates as #GTlsConnection would. -For example, certificate constraints cannot be honored, and some -revocation checks cannot be performed. The best way to verify TLS +For example, certificate constraints may not be honored, and +revocation checks may not be performed. The best way to verify TLS certificates used by a TLS connection is to let #GTlsConnection handle the verification. The TLS backend may attempt to look up and add missing certificates -to the chain. Since GLib 2.70, this may involve HTTP requests to -download missing certificates. +to the chain. This may involve HTTP requests to download missing +certificates. This function can block. Use g_tls_database_verify_chain_async() to perform the verification operation asynchronously. diff --git a/gio/src/gio_enums.defs b/gio/src/gio_enums.defs index ef399fa8..c0d53e24 100644 --- a/gio/src/gio_enums.defs +++ b/gio/src/gio_enums.defs @@ -896,7 +896,8 @@ ;; G_DBUS_PROXY_FLAGS_DO_NOT_CONNECT_SIGNALS = (1<<1), ;; G_DBUS_PROXY_FLAGS_DO_NOT_AUTO_START = (1<<2), ;; G_DBUS_PROXY_FLAGS_GET_INVALIDATED_PROPERTIES = (1<<3), -;; G_DBUS_PROXY_FLAGS_DO_NOT_AUTO_START_AT_CONSTRUCTION = (1<<4) +;; G_DBUS_PROXY_FLAGS_DO_NOT_AUTO_START_AT_CONSTRUCTION = (1<<4), +;; G_DBUS_PROXY_FLAGS_NO_MATCH_RULE GLIB_AVAILABLE_ENUMERATOR_IN_2_72 = (1<<5) ;; } GDBusProxyFlags; (define-flags-extended DBusProxyFlags @@ -909,6 +910,7 @@ '("do-not-auto-start" "G_DBUS_PROXY_FLAGS_DO_NOT_AUTO_START" "(1<<2)") '("get-invalidated-properties" "G_DBUS_PROXY_FLAGS_GET_INVALIDATED_PROPERTIES" "(1<<3)") '("do-not-auto-start-at-construction" "G_DBUS_PROXY_FLAGS_DO_NOT_AUTO_START_AT_CONSTRUCTION" "(1<<4)") + '("no-match-rule" "G_DBUS_PROXY_FLAGS_NO_MATCH_RULE" "(1<<5)") ) ) @@ -1243,6 +1245,7 @@ ;; G_CREDENTIALS_TYPE_SOLARIS_UCRED, ;; G_CREDENTIALS_TYPE_NETBSD_UNPCBID, ;; G_CREDENTIALS_TYPE_APPLE_XUCRED, +;; G_CREDENTIALS_TYPE_WIN32_PID, ;; } GCredentialsType; (define-enum-extended CredentialsType @@ -1256,6 +1259,7 @@ '("solaris-ucred" "G_CREDENTIALS_TYPE_SOLARIS_UCRED" "4") '("netbsd-unpcbid" "G_CREDENTIALS_TYPE_NETBSD_UNPCBID" "5") '("apple-xucred" "G_CREDENTIALS_TYPE_APPLE_XUCRED" "6") + '("win32-pid" "G_CREDENTIALS_TYPE_WIN32_PID" "7") ) ) @@ -1319,7 +1323,8 @@ ;; G_TLS_ERROR_HANDSHAKE, ;; G_TLS_ERROR_CERTIFICATE_REQUIRED, ;; G_TLS_ERROR_EOF, -;; G_TLS_ERROR_INAPPROPRIATE_FALLBACK +;; G_TLS_ERROR_INAPPROPRIATE_FALLBACK, +;; G_TLS_ERROR_BAD_CERTIFICATE_PASSWORD ;; } GTlsError; (define-enum-extended TlsError @@ -1334,6 +1339,7 @@ '("certificate-required" "G_TLS_ERROR_CERTIFICATE_REQUIRED" "5") '("eof" "G_TLS_ERROR_EOF" "6") '("inappropriate-fallback" "G_TLS_ERROR_INAPPROPRIATE_FALLBACK" "7") + '("bad-certificate-password" "G_TLS_ERROR_BAD_CERTIFICATE_PASSWORD" "8") ) ) @@ -1664,7 +1670,8 @@ ;; G_SUBPROCESS_FLAGS_STDERR_PIPE = (1u << 4), ;; G_SUBPROCESS_FLAGS_STDERR_SILENCE = (1u << 5), ;; G_SUBPROCESS_FLAGS_STDERR_MERGE = (1u << 6), -;; G_SUBPROCESS_FLAGS_INHERIT_FDS = (1u << 7) +;; G_SUBPROCESS_FLAGS_INHERIT_FDS = (1u << 7), +;; G_SUBPROCESS_FLAGS_SEARCH_PATH_FROM_ENVP = (1u << 8) ;; } GSubprocessFlags; (define-flags-extended SubprocessFlags @@ -1680,6 +1687,7 @@ '("stderr-silence" "G_SUBPROCESS_FLAGS_STDERR_SILENCE" "(1u << 5)") '("stderr-merge" "G_SUBPROCESS_FLAGS_STDERR_MERGE" "(1u << 6)") '("inherit-fds" "G_SUBPROCESS_FLAGS_INHERIT_FDS" "(1u << 7)") + '("search-path-from-envp" "G_SUBPROCESS_FLAGS_SEARCH_PATH_FROM_ENVP" "(1u << 8)") ) ) diff --git a/gio/src/gio_methods.defs b/gio/src/gio_methods.defs index 1887a2fd..63fa80c2 100644 --- a/gio/src/gio_methods.defs +++ b/gio/src/gio_methods.defs @@ -1338,6 +1338,7 @@ '("do-not-auto-start" "G_DBUS_PROXY_FLAGS_DO_NOT_AUTO_START") '("get-invalidated-properties" "G_DBUS_PROXY_FLAGS_GET_INVALIDATED_PROPERTIES") '("do-not-auto-start-at-construction" "G_DBUS_PROXY_FLAGS_DO_NOT_AUTO_START_AT_CONSTRUCTION") + '("no-match-rule" "G_DBUS_PROXY_FLAGS_NO_MATCH_RULE") ) ) @@ -1540,6 +1541,7 @@ '("solaris-ucred" "G_CREDENTIALS_TYPE_SOLARIS_UCRED") '("netbsd-unpcbid" "G_CREDENTIALS_TYPE_NETBSD_UNPCBID") '("apple-xucred" "G_CREDENTIALS_TYPE_APPLE_XUCRED") + '("win32-pid" "G_CREDENTIALS_TYPE_WIN32_PID") ) ) @@ -1584,6 +1586,7 @@ '("certificate-required" "G_TLS_ERROR_CERTIFICATE_REQUIRED") '("eof" "G_TLS_ERROR_EOF") '("inappropriate-fallback" "G_TLS_ERROR_INAPPROPRIATE_FALLBACK") + '("bad-certificate-password" "G_TLS_ERROR_BAD_CERTIFICATE_PASSWORD") ) ) @@ -1785,6 +1788,7 @@ '("stderr-silence" "G_SUBPROCESS_FLAGS_STDERR_SILENCE") '("stderr-merge" "G_SUBPROCESS_FLAGS_STDERR_MERGE") '("inherit-fds" "G_SUBPROCESS_FLAGS_INHERIT_FDS") + '("search-path-from-envp" "G_SUBPROCESS_FLAGS_SEARCH_PATH_FROM_ENVP") ) ) @@ -6862,6 +6866,46 @@ +;; From gdebugcontrollerdbus.h + +(define-function g_debug_controller_dbus_new + (c-name "g_debug_controller_dbus_new") + (is-constructor-of "GDebugControllerDbus") + (return-type "GDebugControllerDBus*") + (parameters + '("GDBusConnection*" "connection") + '("GCancellable*" "cancellable") + '("GError**" "error") + ) +) + +(define-method stop + (of-object "GDebugControllerDBus") + (c-name "g_debug_controller_dbus_stop") + (return-type "none") +) + + + +;; From gdebugcontroller.h + +(define-method get_debug_enabled + (of-object "GDebugController") + (c-name "g_debug_controller_get_debug_enabled") + (return-type "gboolean") +) + +(define-method set_debug_enabled + (of-object "GDebugController") + (c-name "g_debug_controller_set_debug_enabled") + (return-type "none") + (parameters + '("gboolean" "debug_enabled") + ) +) + + + ;; From gdelayedsettingsbackend.h (define-function g_delayed_settings_backend_get_type @@ -8739,6 +8783,32 @@ ) ) +(define-method move_async + (of-object "GFile") + (c-name "g_file_move_async") + (return-type "none") + (parameters + '("GFile*" "destination") + '("GFileCopyFlags" "flags") + '("int" "io_priority") + '("GCancellable*" "cancellable") + '("GFileProgressCallback" "progress_callback") + '("gpointer" "progress_callback_data") + '("GAsyncReadyCallback" "callback") + '("gpointer" "user_data") + ) +) + +(define-method move_finish + (of-object "GFile") + (c-name "g_file_move_finish") + (return-type "gboolean") + (parameters + '("GAsyncResult*" "result") + '("GError**" "error") + ) +) + (define-method make_directory (of-object "GFile") (c-name "g_file_make_directory") @@ -11590,6 +11660,10 @@ +;; From giowin32-afunix.h + + + ;; From giowin32-priv.h (define-function g_win32_output_stream_new_from_fd @@ -18590,6 +18664,25 @@ (return-type "GType") ) +(define-function g_resolver_records_from_res_query + (c-name "g_resolver_records_from_res_query") + (return-type "GList*") + (parameters + '("const-gchar*" "rrname") + '("gint" "rrtype") + '("const-guint8*" "answer") + '("gssize" "len") + '("gint" "herr") + '("GError**" "error") + ) +) + +(define-method to_rrtype + (of-object "GResolverRecordType") + (c-name "g_resolver_record_type_to_rrtype") + (return-type "gint") +) + ;; From gthreadedsocketservice.h @@ -18704,6 +18797,27 @@ ) ) +(define-function g_tls_certificate_new_from_pkcs12 + (c-name "g_tls_certificate_new_from_pkcs12") + (return-type "GTlsCertificate*") + (parameters + '("const-guint8*" "data") + '("gsize" "length") + '("const-gchar*" "password") + '("GError**" "error") + ) +) + +(define-function g_tls_certificate_new_from_file_with_password + (c-name "g_tls_certificate_new_from_file_with_password") + (return-type "GTlsCertificate*") + (parameters + '("const-gchar*" "file") + '("const-gchar*" "password") + '("GError**" "error") + ) +) + (define-function g_tls_certificate_new_from_file (c-name "g_tls_certificate_new_from_file") (return-type "GTlsCertificate*") @@ -20963,6 +21077,10 @@ +;; From gwin32sid.h + + + ;; From gwin32volumemonitor.h diff --git a/gio/src/gio_signals.defs b/gio/src/gio_signals.defs index 3036c5e0..7c56f76c 100644 --- a/gio/src/gio_signals.defs +++ b/gio/src/gio_signals.defs @@ -2198,6 +2198,7 @@ (readable #t) (writable #t) (construct-only #f) + (deprecated #t) (default-value "G_TLS_CERTIFICATE_UNKNOWN_CA | G_TLS_CERTIFICATE_BAD_IDENTITY | G_TLS_CERTIFICATE_NOT_ACTIVATED | G_TLS_CERTIFICATE_EXPIRED | G_TLS_CERTIFICATE_REVOKED | G_TLS_CERTIFICATE_INSECURE | G_TLS_CERTIFICATE_GENERIC_ERROR") ) @@ -2371,6 +2372,25 @@ (construct-only #f) ) +(define-property pkcs12-data + (of-object "GTlsCertificate") + (prop-type "GParamBoxed") + (docs "The PKCS #12 data used for construction") + (readable #f) + (writable #t) + (construct-only #t) +) + +(define-property password + (of-object "GTlsCertificate") + (prop-type "GParamString") + (docs "Password used when constructing from bytes") + (readable #f) + (writable #t) + (construct-only #t) + (default-value "") +) + ;; From GTlsClientConnection (define-property accepted-cas @@ -2409,6 +2429,7 @@ (readable #t) (writable #t) (construct-only #f) + (deprecated #t) (default-value "G_TLS_CERTIFICATE_UNKNOWN_CA | G_TLS_CERTIFICATE_BAD_IDENTITY | G_TLS_CERTIFICATE_NOT_ACTIVATED | G_TLS_CERTIFICATE_EXPIRED | G_TLS_CERTIFICATE_REVOKED | G_TLS_CERTIFICATE_INSECURE | G_TLS_CERTIFICATE_GENERIC_ERROR") ) @@ -3105,6 +3126,7 @@ (of-object "GDBusProxy") (return-type "void") (flags "Run Last, Must Collect") + (detailed #t) (parameters '("const-gchar*" "p0") '("const-gchar*" "p1") diff --git a/gio/src/gio_signals.defs.patch b/gio/src/gio_signals.defs.patch index cfa13827..22a915c7 100644 --- a/gio/src/gio_signals.defs.patch +++ b/gio/src/gio_signals.defs.patch @@ -1,5 +1,5 @@ ---- tools/gen_scripts/../../gio/src/gio_signals.defs.orig 2019-07-15 15:42:00.493060856 +0200 -+++ tools/gen_scripts/../../gio/src/gio_signals.defs 2019-07-15 15:42:00.513060927 +0200 +--- tools/gen_scripts/../../gio/src/gio_signals.defs.orig 2022-04-06 10:10:49.446569490 +0200 ++++ tools/gen_scripts/../../gio/src/gio_signals.defs 2022-04-06 10:20:32.616923494 +0200 @@ -87,11 +87,11 @@ (return-type "void") (flags "Run Last, Must Collect") @@ -75,7 +75,7 @@ (define-property settings-schema (of-object "GSettings") -@@ -2808,23 +2808,23 @@ +@@ -2926,23 +2926,23 @@ (parameters '("GDBusObjectProxy*" "p0") '("GDBusProxy*" "p1") @@ -102,7 +102,7 @@ (define-property bus-type (of-object "GDBusObjectManagerClient") -@@ -2997,23 +2997,23 @@ +@@ -3115,12 +3115,12 @@ (define-signal g-properties-changed (of-object "GDBusProxy") (return-type "void") @@ -117,8 +117,9 @@ (define-signal g-signal (of-object "GDBusProxy") - (return-type "void") +@@ -3128,11 +3128,11 @@ (flags "Run Last, Must Collect") + (detailed #t) (parameters '("const-gchar*" "p0") '("const-gchar*" "p1") diff --git a/glib/src/glib_docs.xml b/glib/src/glib_docs.xml index df9b6a57..dee3bf00 100644 --- a/glib/src/glib_docs.xml +++ b/glib/src/glib_docs.xml @@ -91,6 +91,15 @@ transformation functions to g_object_bind_property_full(). </parameters> </enum> +<property name="GBindingGroup:source"> +<description> +The source object used for binding properties. + +Since: 2.72 + +</description> +</property> + <enum name="GBookmarkFileError"> <description> Error codes returned by bookmark file parsing. @@ -177,7 +186,7 @@ connection. </description> <parameters> <parameter name="G_CONNECT_AFTER"> -<parameter_description> whether the handler should be called before or after the +<parameter_description> whether the handler should be called before or after the default handler of the signal. </parameter_description> </parameter> @@ -321,8 +330,8 @@ Enumeration representing a month; values are %G_DATE_JANUARY, <enum name="GDateWeekday"> <description> -Enumeration representing a day of the week; #G_DATE_MONDAY, -#G_DATE_TUESDAY, etc. #G_DATE_BAD_WEEKDAY is an invalid weekday. +Enumeration representing a day of the week; %G_DATE_MONDAY, +%G_DATE_TUESDAY, etc. %G_DATE_BAD_WEEKDAY is an invalid weekday. </description> <parameters> @@ -1015,6 +1024,29 @@ Since: 2.50 </parameters> </enum> +<enum name="GMainContextFlags"> +<description> +Flags to pass to g_main_context_new_with_flags() which affect the behaviour +of a #GMainContext. + +Since: 2.72 + +</description> +<parameters> +<parameter name="G_MAIN_CONTEXT_FLAGS_NONE"> +<parameter_description> Default behaviour. +</parameter_description> +</parameter> +<parameter name="G_MAIN_CONTEXT_FLAGS_OWNERLESS_POLLING"> +<parameter_description> Assume that polling for events will +free the thread to process other jobs. That's useful if you're using +`g_main_context_{prepare,query,check,dispatch}` to integrate GMainContext in +other event loops. +</parameter_description> +</parameter> +</parameters> +</enum> + <enum name="GMarkupCollectType"> <description> A mixed enumerated type and flags field. You must specify one type @@ -1559,8 +1591,8 @@ of a single line of characters (even if it actually contains newlines). The "start of line" metacharacter ("^") matches only at the start of the string, while the "end of line" metacharacter ("$") matches only at the end of the string, or before a terminating -newline (unless #G_REGEX_DOLLAR_ENDONLY is set). When -#G_REGEX_MULTILINE is set, the "start of line" and "end of line" +newline (unless %G_REGEX_DOLLAR_ENDONLY is set). When +%G_REGEX_MULTILINE is set, the "start of line" and "end of line" constructs match immediately following or immediately before any newline in the string, respectively, as well as at the very start and end. This can be changed within a pattern by a "(?m)" option @@ -1595,7 +1627,7 @@ metacharacter. matches only at the end of the string. Without this option, a dollar also matches immediately before the final character if it is a newline (but not before any other newlines). This option -is ignored if #G_REGEX_MULTILINE is set. +is ignored if %G_REGEX_MULTILINE is set. </parameter_description> </parameter> <parameter name="G_REGEX_UNGREEDY"> @@ -1974,7 +2006,7 @@ metacharacter. <parameter name="G_REGEX_MATCH_NOTBOL"> <parameter_description> Specifies that first character of the string is not the beginning of a line, so the circumflex metacharacter should -not match before it. Setting this without #G_REGEX_MULTILINE (at +not match before it. Setting this without %G_REGEX_MULTILINE (at compile time) causes circumflex never to match. This option affects only the behaviour of the circumflex metacharacter, it does not affect "\A". @@ -1984,7 +2016,7 @@ affect "\A". <parameter_description> Specifies that the end of the subject string is not the end of a line, so the dollar metacharacter should not match it nor (except in multiline mode) a newline immediately before it. -Setting this without #G_REGEX_MULTILINE (at compile time) causes +Setting this without %G_REGEX_MULTILINE (at compile time) causes dollar never to match. This option affects only the behaviour of the dollar metacharacter, it does not affect "\Z" or "\z". </parameter_description> @@ -2051,18 +2083,18 @@ U+2029 PARAGRAPH SEPARATOR. Since: 2.34 </parameter_description> </parameter> <parameter name="G_REGEX_MATCH_PARTIAL_SOFT"> -<parameter_description> An alias for #G_REGEX_MATCH_PARTIAL. Since: 2.34 +<parameter_description> An alias for %G_REGEX_MATCH_PARTIAL. Since: 2.34 </parameter_description> </parameter> <parameter name="G_REGEX_MATCH_PARTIAL_HARD"> <parameter_description> Turns on the partial matching feature. In contrast to -to #G_REGEX_MATCH_PARTIAL_SOFT, this stops matching as soon as a partial match +to %G_REGEX_MATCH_PARTIAL_SOFT, this stops matching as soon as a partial match is found, without continuing to search for a possible complete match. See g_match_info_is_partial_match() for more information. Since: 2.34 </parameter_description> </parameter> <parameter name="G_REGEX_MATCH_NOTEMPTY_ATSTART"> -<parameter_description> Like #G_REGEX_MATCH_NOTEMPTY, but only applied to +<parameter_description> Like %G_REGEX_MATCH_NOTEMPTY, but only applied to the start of the matched string. For anchored patterns this can only happen for pattern containing "\K". Since: 2.34 </parameter_description> @@ -2175,6 +2207,67 @@ call to the accumulator function for a signal emission. Since 2.68. </parameters> </enum> +<signal name="GSignalGroup::bind"> +<description> +This signal is emitted when #GSignalGroup:target is set to a new value +other than %NULL. It is similar to #GObject::notify on `target` except it +will not emit when #GSignalGroup:target is %NULL and also allows for +receiving the #GObject without a data-race. + +Since: 2.72 + +</description> +<parameters> +<parameter name="self"> +<parameter_description> the #GSignalGroup +</parameter_description> +</parameter> +<parameter name="instance"> +<parameter_description> a #GObject containing the new value for #GSignalGroup:target +</parameter_description> +</parameter> +</parameters> +<return></return> +</signal> + +<signal name="GSignalGroup::unbind"> +<description> +This signal is emitted when the target instance of @self is set to a +new #GObject. + +This signal will only be emitted if the previous target of @self is +non-%NULL. + +Since: 2.72 + +</description> +<parameters> +<parameter name="self"> +<parameter_description> a #GSignalGroup +</parameter_description> +</parameter> +</parameters> +<return></return> +</signal> + +<property name="GSignalGroup:target"> +<description> +The target instance used when connecting signals. + +Since: 2.72 + +</description> +</property> + +<property name="GSignalGroup:target-type"> +<description> +The #GType of the target property. + +Since: 2.72 + +</description> +</property> + <enum name="GSignalMatchType"> <description> The match types specify what g_signal_handlers_block_matched(), @@ -3651,6 +3744,30 @@ Old South Arabian. Since 2.26 <parameter_description> Yezidi. Since: 2.66 </parameter_description> </parameter> +<parameter name="G_UNICODE_SCRIPT_CYPRO_MINOAN"> +<parameter_description> Cypro-Minoan. Since: 2.72 +</parameter_description> +</parameter> +<parameter name="G_UNICODE_SCRIPT_OLD_UYGHUR"> +<parameter_description> Old Uyghur. Since: 2.72 +</parameter_description> +</parameter> +<parameter name="G_UNICODE_SCRIPT_TANGSA"> +<parameter_description> Tangsa. Since: 2.72 +</parameter_description> +</parameter> +<parameter name="G_UNICODE_SCRIPT_TOTO"> +<parameter_description> Toto. Since: 2.72 +</parameter_description> +</parameter> +<parameter name="G_UNICODE_SCRIPT_VITHKUQI"> +<parameter_description> Vithkuqi. Since: 2.72 +</parameter_description> +</parameter> +<parameter name="G_UNICODE_SCRIPT_MATH"> +<parameter_description> Mathematical notation. Since: 2.72 +</parameter_description> +</parameter> </parameters> </enum> @@ -4280,6 +4397,83 @@ or on error. </return> </function> +<function name="g_aligned_alloc"> +<description> +This function is similar to g_malloc(), allocating (@n_blocks * @n_block_bytes) +bytes, but care is taken to align the allocated memory to with the given +alignment value. Additionally, it will detect possible overflow during +multiplication. + +Aligned memory allocations returned by this function can only be +freed using g_aligned_free(). + +Since: 2.72 + +</description> +<parameters> +<parameter name="n_blocks"> +<parameter_description> the number of blocks to allocate +</parameter_description> +</parameter> +<parameter name="n_block_bytes"> +<parameter_description> the size of each block in bytes +</parameter_description> +</parameter> +<parameter name="alignment"> +<parameter_description> the alignment to be enforced, which must be a positive power of 2 +and a multiple of `sizeof(void*)` +</parameter_description> +</parameter> +</parameters> +<return> the allocated memory + +</return> +</function> + +<function name="g_aligned_alloc0"> +<description> +This function is similar to g_aligned_alloc(), but it will +also clear the allocated memory before returning it. + +Since: 2.72 + +</description> +<parameters> +<parameter name="n_blocks"> +<parameter_description> the number of blocks to allocate +</parameter_description> +</parameter> +<parameter name="n_block_bytes"> +<parameter_description> the size of each block in bytes +</parameter_description> +</parameter> +<parameter name="alignment"> +<parameter_description> the alignment to be enforced, which must be a positive power of 2 +and a multiple of `sizeof(void*)` +</parameter_description> +</parameter> +</parameters> +<return> the allocated, cleared memory + +</return> +</function> + +<function name="g_aligned_free"> +<description> +Frees the memory allocated by g_aligned_alloc(). + +Since: 2.72 + +</description> +<parameters> +<parameter name="mem"> +<parameter_description> the memory to deallocate +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_alloca"> <description> Allocates @size bytes on the stack; these bytes will be freed when the current @@ -4324,6 +4518,27 @@ not upon exit of the enclosing function scope. </return> </function> +<function name="g_alloca0"> +<description> +Wraps g_alloca() and initializes allocated memory to zeroes. +If @size is `0` it returns %NULL. + +Note that the @size argument will be evaluated multiple times. + +Since: 2.72 + +</description> +<parameters> +<parameter name="size"> +<parameter_description> number of bytes to allocate. +</parameter_description> +</parameter> +</parameters> +<return> space for @size bytes, allocated on the stack + +</return> +</function> + <function name="g_array_append_val"> <description> Adds the value on to the end of the array. The array will grow in @@ -5036,7 +5251,7 @@ 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, including the terminating +be larger than %G_ASCII_DTOSTR_BUF_SIZE bytes, including the terminating nul character, which is always added. @@ -5066,6 +5281,9 @@ 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 @format must just be a single format specifier +starting with `%`, expecting a #gdouble argument. + The returned buffer is guaranteed to be nul-terminated. If you just want to want to serialize the value into a @@ -5084,7 +5302,7 @@ string, use g_ascii_dtostr(). </parameter> <parameter name="format"> <parameter_description> The printf()-style format to use for the -code to use for converting. +code to use for converting </parameter_description> </parameter> <parameter name="d"> @@ -5521,7 +5739,9 @@ Since: 2.54 <function name="g_ascii_strncasecmp"> <description> Compare @s1 and @s2, ignoring the case of ASCII characters and any -characters after the first @n in each string. +characters after the first @n in each string. If either string is +less than @n bytes long, comparison will stop at the first nul byte +encountered. Unlike the BSD strcasecmp() function, this only recognizes standard ASCII letters and ignores the locale, treating all non-ASCII @@ -8505,6 +8725,210 @@ Since: 2.26 </return> </function> +<function name="g_binding_group_bind"> +<description> +Creates a binding between @source_property on the source object +and @target_property on @target. Whenever the @source_property +is changed the @target_property is updated using the same value. +The binding flag %G_BINDING_SYNC_CREATE is automatically specified. + +See g_object_bind_property() for more information. + +Since: 2.72 + +</description> +<parameters> +<parameter name="self"> +<parameter_description> the #GBindingGroup +</parameter_description> +</parameter> +<parameter name="source_property"> +<parameter_description> the property on the source to bind +</parameter_description> +</parameter> +<parameter name="target"> +<parameter_description> the target #GObject +</parameter_description> +</parameter> +<parameter name="target_property"> +<parameter_description> the property on @target to bind +</parameter_description> +</parameter> +<parameter name="flags"> +<parameter_description> the flags used to create the #GBinding +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + +<function name="g_binding_group_bind_full"> +<description> +Creates a binding between @source_property on the source object and +@target_property on @target, allowing you to set the transformation +functions to be used by the binding. The binding flag +%G_BINDING_SYNC_CREATE is automatically specified. + +See g_object_bind_property_full() for more information. + +Since: 2.72 + +</description> +<parameters> +<parameter name="self"> +<parameter_description> the #GBindingGroup +</parameter_description> +</parameter> +<parameter name="source_property"> +<parameter_description> the property on the source to bind +</parameter_description> +</parameter> +<parameter name="target"> +<parameter_description> the target #GObject +</parameter_description> +</parameter> +<parameter name="target_property"> +<parameter_description> the property on @target to bind +</parameter_description> +</parameter> +<parameter name="flags"> +<parameter_description> the flags used to create the #GBinding +</parameter_description> +</parameter> +<parameter name="transform_to"> +<parameter_description> the transformation function +from the source object to the @target, or %NULL to use the default +</parameter_description> +</parameter> +<parameter name="transform_from"> +<parameter_description> the transformation function +from the @target to the source object, or %NULL to use the default +</parameter_description> +</parameter> +<parameter name="user_data"> +<parameter_description> custom data to be passed to the transformation +functions, or %NULL +</parameter_description> +</parameter> +<parameter name="user_data_destroy"> +<parameter_description> function to be called when disposing the binding, +to free the resources used by the transformation functions +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + +<function name="g_binding_group_bind_with_closures"> +<description> +Creates a binding between @source_property on the source object and +@target_property on @target, allowing you to set the transformation +functions to be used by the binding. The binding flag +%G_BINDING_SYNC_CREATE is automatically specified. + +This function is the language bindings friendly version of +g_binding_group_bind_property_full(), using #GClosures +instead of function pointers. + +See g_object_bind_property_with_closures() for more information. + +Since: 2.72 + +</description> +<parameters> +<parameter name="self"> +<parameter_description> the #GBindingGroup +</parameter_description> +</parameter> +<parameter name="source_property"> +<parameter_description> the property on the source to bind +</parameter_description> +</parameter> +<parameter name="target"> +<parameter_description> the target #GObject +</parameter_description> +</parameter> +<parameter name="target_property"> +<parameter_description> the property on @target to bind +</parameter_description> +</parameter> +<parameter name="flags"> +<parameter_description> the flags used to create the #GBinding +</parameter_description> +</parameter> +<parameter name="transform_to"> +<parameter_description> a #GClosure wrapping the +transformation function from the source object to the @target, +or %NULL to use the default +</parameter_description> +</parameter> +<parameter name="transform_from"> +<parameter_description> a #GClosure wrapping the +transformation function from the @target to the source object, +or %NULL to use the default +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + +<function name="g_binding_group_dup_source"> +<description> +Gets the source object used for binding properties. + +Since: 2.72 + +</description> +<parameters> +<parameter name="self"> +<parameter_description> the #GBindingGroup +</parameter_description> +</parameter> +</parameters> +<return> a #GObject or %NULL. + +</return> +</function> + +<function name="g_binding_group_new"> +<description> +Creates a new #GBindingGroup. + +Since: 2.72 + +</description> +<parameters> +</parameters> +<return> a new #GBindingGroup + +</return> +</function> + +<function name="g_binding_group_set_source"> +<description> +Sets @source as the source object used for creating property +bindings. If there is already a source object all bindings from it +will be removed. + +Note that all properties that have been bound must exist on @source. + +Since: 2.72 + +</description> +<parameters> +<parameter name="self"> +<parameter_description> the #GBindingGroup +</parameter_description> +</parameter> +<parameter name="source"> +<parameter_description> the source #GObject, +or %NULL to clear it +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_binding_unbind"> <description> Explicitly releases the binding between the source and the target @@ -8789,7 +9213,7 @@ Since: 2.12 Gets the time the bookmark for @uri was added to @bookmark In the event the URI cannot be found, -1 is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. Since: 2.12 Deprecated: 2.66: Use g_bookmark_file_get_added_date_time() instead, as @@ -8820,7 +9244,7 @@ Deprecated: 2.66: Use g_bookmark_file_get_added_date_time() instead, as Gets the time the bookmark for @uri was added to @bookmark In the event the URI cannot be found, %NULL is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. Since: 2.66 @@ -8853,11 +9277,11 @@ the returned data. The string returned in @app_exec must be freed. In the event the URI cannot be found, %FALSE is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. In the +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. In the event that no application with name @app_name has registered a bookmark for @uri, %FALSE is returned and error is set to -#G_BOOKMARK_FILE_ERROR_APP_NOT_REGISTERED. In the event that unquoting -the command line fails, an error of the #G_SHELL_ERROR domain is +%G_BOOKMARK_FILE_ERROR_APP_NOT_REGISTERED. In the event that unquoting +the command line fails, an error of the %G_SHELL_ERROR domain is set and %FALSE is returned. Since: 2.12 @@ -8909,11 +9333,11 @@ the returned data. The string returned in @app_exec must be freed. In the event the URI cannot be found, %FALSE is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. In the +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. In the event that no application with name @app_name has registered a bookmark for @uri, %FALSE is returned and error is set to -#G_BOOKMARK_FILE_ERROR_APP_NOT_REGISTERED. In the event that unquoting -the command line fails, an error of the #G_SHELL_ERROR domain is +%G_BOOKMARK_FILE_ERROR_APP_NOT_REGISTERED. In the event that unquoting +the command line fails, an error of the %G_SHELL_ERROR domain is set and %FALSE is returned. Since: 2.66 @@ -8960,7 +9384,7 @@ Retrieves the names of the applications that have registered the bookmark for @uri. In the event the URI cannot be found, %NULL is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. Since: 2.12 @@ -8994,7 +9418,7 @@ Use g_strfreev() to free it. Retrieves the description of the bookmark for @uri. In the event the URI cannot be found, %NULL is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. Since: 2.12 @@ -9024,7 +9448,7 @@ URI cannot be found. Retrieves the list of group names of the bookmark for @uri. In the event the URI cannot be found, %NULL is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. The returned array is %NULL terminated, so @length may optionally be %NULL. @@ -9061,7 +9485,7 @@ Use g_strfreev() to free it. Gets the icon of the bookmark for @uri. In the event the URI cannot be found, %FALSE is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. Since: 2.12 @@ -9099,9 +9523,9 @@ You should free the returned strings. Gets whether the private flag of the bookmark for @uri is set. In the event the URI cannot be found, %FALSE is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. In the +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. In the event that the private flag cannot be found, %FALSE is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_INVALID_VALUE. +@error is set to %G_BOOKMARK_FILE_ERROR_INVALID_VALUE. Since: 2.12 @@ -9130,9 +9554,9 @@ Since: 2.12 Retrieves the MIME type of the resource pointed by @uri. In the event the URI cannot be found, %NULL is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. In the +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. In the event that the MIME type cannot be found, %NULL is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_INVALID_VALUE. +@error is set to %G_BOOKMARK_FILE_ERROR_INVALID_VALUE. Since: 2.12 @@ -9162,7 +9586,7 @@ URI cannot be found. Gets the time when the bookmark for @uri was last modified. In the event the URI cannot be found, -1 is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. Since: 2.12 Deprecated: 2.66: Use g_bookmark_file_get_modified_date_time() instead, as @@ -9193,7 +9617,7 @@ Deprecated: 2.66: Use g_bookmark_file_get_modified_date_time() instead, as Gets the time when the bookmark for @uri was last modified. In the event the URI cannot be found, %NULL is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. Since: 2.66 @@ -9242,7 +9666,7 @@ Returns the title of the bookmark for @uri. If @uri is %NULL, the title of @bookmark is returned. In the event the URI cannot be found, %NULL is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. Since: 2.12 @@ -9297,7 +9721,7 @@ Use g_strfreev() to free it. Gets the time the bookmark for @uri was last visited. In the event the URI cannot be found, -1 is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. Since: 2.12 Deprecated: 2.66: Use g_bookmark_file_get_visited_date_time() instead, as @@ -9328,7 +9752,7 @@ Deprecated: 2.66: Use g_bookmark_file_get_visited_date_time() instead, as Gets the time the bookmark for @uri was last visited. In the event the URI cannot be found, %NULL is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. Since: 2.66 @@ -9358,7 +9782,7 @@ Checks whether the bookmark for @uri inside @bookmark has been registered by application @name. In the event the URI cannot be found, %FALSE is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. Since: 2.12 @@ -9392,7 +9816,7 @@ Checks whether @group appears in the list of groups to which the bookmark for @uri belongs to. In the event the URI cannot be found, %FALSE is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. Since: 2.12 @@ -9546,7 +9970,7 @@ existing bookmark for @new_uri will be overwritten. If @new_uri is %NULL, then the bookmark is removed. In the event the URI cannot be found, %FALSE is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. Since: 2.12 @@ -9598,10 +10022,10 @@ Removes application registered with @name from the list of applications that have registered a bookmark for @uri inside @bookmark. In the event the URI cannot be found, %FALSE is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. In the event that no application with name @app_name has registered a bookmark for @uri, %FALSE is returned and error is set to -#G_BOOKMARK_FILE_ERROR_APP_NOT_REGISTERED. +%G_BOOKMARK_FILE_ERROR_APP_NOT_REGISTERED. Since: 2.12 @@ -9635,9 +10059,9 @@ Removes @group from the list of groups to which the bookmark for @uri belongs to. In the event the URI cannot be found, %FALSE is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND. In the event no group was defined, %FALSE is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_INVALID_VALUE. +@error is set to %G_BOOKMARK_FILE_ERROR_INVALID_VALUE. Since: 2.12 @@ -9770,10 +10194,10 @@ current time will be used. If you try to remove an application by setting its registration count to zero, and no bookmark for @uri is found, %FALSE is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND; similarly, +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND; similarly, in the event that no application @name has registered a bookmark for @uri, %FALSE is returned and error is set to -#G_BOOKMARK_FILE_ERROR_APP_NOT_REGISTERED. Otherwise, if no bookmark +%G_BOOKMARK_FILE_ERROR_APP_NOT_REGISTERED. Otherwise, if no bookmark for @uri is found, one is created. Since: 2.12 @@ -9841,10 +10265,10 @@ the list of registered applications. If you try to remove an application by setting its registration count to zero, and no bookmark for @uri is found, %FALSE is returned and -@error is set to #G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND; similarly, +@error is set to %G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND; similarly, in the event that no application @name has registered a bookmark for @uri, %FALSE is returned and error is set to -#G_BOOKMARK_FILE_ERROR_APP_NOT_REGISTERED. Otherwise, if no bookmark +%G_BOOKMARK_FILE_ERROR_APP_NOT_REGISTERED. Otherwise, if no bookmark for @uri is found, one is created. Since: 2.66 @@ -10291,7 +10715,7 @@ boxed type with name @name. Boxed type handling functions have to be provided to copy and free opaque boxed structures of this type. -For the general case, it is recommended to use #G_DEFINE_BOXED_TYPE +For the general case, it is recommended to use G_DEFINE_BOXED_TYPE() instead of calling g_boxed_type_register_static() directly. The macro will create the appropriate `*_get_type()` function for the boxed type. @@ -10331,7 +10755,7 @@ parameters (reading from left to right) is used. No attempt is made to force the resulting filename to be an absolute path. If the first element is a relative path, the result will -be a relative path. +be a relative path. </description> @@ -10345,8 +10769,8 @@ be a relative path. </parameter_description> </parameter> </parameters> -<return> a newly-allocated string that must be freed with -g_free(). +<return> a newly-allocated string that +must be freed with g_free(). </return> </function> @@ -10368,8 +10792,8 @@ Since: 2.56 </parameter_description> </parameter> </parameters> -<return> a newly-allocated string that must be freed -with g_free(). +<return> a newly-allocated string that +must be freed with g_free(). </return> </function> @@ -10390,8 +10814,8 @@ array of strings containing the path elements. </parameter_description> </parameter> </parameters> -<return> a newly-allocated string that must be freed -with g_free(). +<return> a newly-allocated string that +must be freed with g_free(). </return> </function> @@ -10441,8 +10865,8 @@ of the separator are ignored. </parameter_description> </parameter> </parameters> -<return> a newly-allocated string that must be freed with -g_free(). +<return> a newly-allocated string that +must be freed with g_free(). </return> </function> @@ -10466,8 +10890,8 @@ array of strings containing the path elements. </parameter_description> </parameter> </parameters> -<return> a newly-allocated string that must be freed -with g_free(). +<return> a newly-allocated string that +must be freed with g_free(). </return> </function> @@ -15264,7 +15688,7 @@ the input string that were successfully converted, or %NULL. Even if the conversion was successful, this may be less than @len if there were partial characters at the end of the input. If the error -#G_CONVERT_ERROR_ILLEGAL_SEQUENCE occurs, the value +%G_CONVERT_ERROR_ILLEGAL_SEQUENCE occurs, the value stored will be the byte offset after the last valid input sequence. </parameter_description> @@ -15411,7 +15835,7 @@ the input string that were successfully converted, or %NULL. Even if the conversion was successful, this may be less than @len if there were partial characters at the end of the input. If the error -#G_CONVERT_ERROR_ILLEGAL_SEQUENCE occurs, the value +%G_CONVERT_ERROR_ILLEGAL_SEQUENCE occurs, the value stored will be the byte offset after the last valid input sequence. </parameter_description> @@ -15729,7 +16153,7 @@ operation, for a member of @datalist. If the previous value was replaced then ownership of the old value (@oldval) is passed to the caller, including the registered destroy notify for it (passed out in @old_destroy). -Its up to the caller to free this as he wishes, which may +Its up to the caller to free this as they wish, which may or may not include using @old_destroy as sometimes replacement should not destroy the object in the normal way. @@ -16737,9 +17161,11 @@ represent an existing day). Free the return value with g_date_free(). <function name="g_date_new_dmy"> <description> -Like g_date_new(), but also sets the value of the date. Assuming the -day-month-year triplet you pass in represents an existing day, the -returned date will be valid. +Create a new #GDate representing the given day-month-year triplet. + +The triplet you pass in must represent a valid date. Use g_date_valid_dmy() +if needed to validate it. The returned #GDate is guaranteed to be non-%NULL +and valid. </description> @@ -16757,15 +17183,18 @@ returned date will be valid. </parameter_description> </parameter> </parameters> -<return> a newly-allocated #GDate initialized with @day, @month, and @year +<return> a newly-allocated #GDate +initialized with @day, @month, and @year </return> </function> <function name="g_date_new_julian"> <description> -Like g_date_new(), but also sets the value of the date. Assuming the -Julian day number you pass in is valid (greater than 0, less than an -unreasonably large number), the returned date will be valid. +Create a new #GDate representing the given Julian date. + +The @julian_day you pass in must be valid. Use g_date_valid_julian() if +needed to validate it. The returned #GDate is guaranteed to be non-%NULL and +valid. </description> @@ -16775,7 +17204,8 @@ unreasonably large number), the returned date will be valid. </parameter_description> </parameter> </parameters> -<return> a newly-allocated #GDate initialized with @julian_day +<return> a newly-allocated #GDate initialized +with @julian_day </return> </function> @@ -19704,7 +20134,7 @@ If the call was successful, it returns %TRUE and sets @contents to the file contents and @length to the length of the file contents in bytes. The string stored in @contents will be nul-terminated, so for text files you can pass %NULL for the @length argument. If the call was not successful, it returns -%FALSE and sets @error. The error domain is #G_FILE_ERROR. Possible error +%FALSE and sets @error. The error domain is %G_FILE_ERROR. Possible error codes are those in the #GFileError enumeration. In the error case, @contents is set to %NULL and @length is set to zero. @@ -19796,8 +20226,8 @@ Since: 2.4 </parameter_description> </parameter> </parameters> -<return> A newly-allocated string with the contents of -the symbolic link, or %NULL if an error occurred. +<return> A newly-allocated string with +the contents of the symbolic link, or %NULL if an error occurred. </return> </function> @@ -19883,7 +20313,7 @@ process, or mapped into memory. Thus, this function will fail if @filename already exists and is open. If the call was successful, it returns %TRUE. If the call was not successful, -it returns %FALSE and sets @error. The error domain is #G_FILE_ERROR. +it returns %FALSE and sets @error. The error domain is %G_FILE_ERROR. Possible error codes are those in the #GFileError enumeration. Note that the name for the temporary file is constructed by appending up @@ -21372,9 +21802,40 @@ Since: 2.14 </parameter_description> </parameter> </parameters> -<return> the path to the specified special directory, or -%NULL if the logical id was not found. The returned string is owned by -GLib and should not be modified or freed. +<return> the path to the specified special +directory, or %NULL if the logical id was not found. The returned string is +owned by GLib and should not be modified or freed. + +</return> +</function> + +<function name="g_get_user_state_dir"> +<description> +Returns a base directory in which to store state files specific to +particular user. + +On UNIX platforms this is determined using the mechanisms described +in the +[XDG Base Directory Specification](http://www.freedesktop.org/Standards/basedir-spec). +In this case the directory retrieved will be `XDG_STATE_HOME`. + +On Windows it follows XDG Base Directory Specification if `XDG_STATE_HOME` is defined. +If `XDG_STATE_HOME` is undefined, the folder to use for local (as opposed +to roaming) application data is used instead. See the +[documentation for `FOLDERID_LocalAppData`](https://docs.microsoft.com/en-us/windows/win32/shell/knownfolderid). +Note that in this case on Windows it will be the same +as what g_get_user_data_dir() returns. + +The return value is cached and modifying it at runtime is not supported, as +it’s not thread-safe to modify environment variables at runtime. + +Since: 2.72 + +</description> +<parameters> +</parameters> +<return> a string owned by GLib that +must not be modified or freed. </return> </function> @@ -22052,6 +22513,30 @@ if you don't want to supply such a function. </return> </function> +<function name="g_hash_table_new_similar"> +<description> +Creates a new #GHashTable like g_hash_table_new_full() with a reference +count of 1. + +It inherits the hash function, the key equal function, the key destroy function, +as well as the value destroy function, from @other_hash_table. + +The returned hash table will be empty; it will not contain the keys +or values from @other_hash_table. + +Since: 2.72 + +</description> +<parameters> +<parameter name="other_hash_table"> +<parameter_description> Another #GHashTable +</parameter_description> +</parameter> +</parameters> +<return> a new #GHashTable +</return> +</function> + <function name="g_hash_table_ref"> <description> Atomically increments the reference count of @hash_table by one. @@ -23647,8 +24132,8 @@ Flushes the write buffer for the GIOChannel. </parameter> </parameters> <return> the status of the operation: One of -#G_IO_STATUS_NORMAL, #G_IO_STATUS_AGAIN, or -#G_IO_STATUS_ERROR. +%G_IO_STATUS_NORMAL, %G_IO_STATUS_AGAIN, or +%G_IO_STATUS_ERROR. </return> </function> @@ -24575,7 +25060,7 @@ or #GIOChannelError <function name="g_io_create_watch"> <description> Creates a #GSource that's dispatched when @condition is met for the -given @channel. For example, if condition is #G_IO_IN, the source will +given @channel. For example, if condition is %G_IO_IN, the source will be dispatched when there's data available for reading. The callback function invoked by the #GSource should be added with @@ -24629,9 +25114,9 @@ Returns the value associated with @key under @group_name as a boolean. If @key cannot be found then %FALSE is returned and @error is set -to #G_KEY_FILE_ERROR_KEY_NOT_FOUND. Likewise, if the value +to %G_KEY_FILE_ERROR_KEY_NOT_FOUND. Likewise, if the value associated with @key cannot be interpreted as a boolean then %FALSE -is returned and @error is set to #G_KEY_FILE_ERROR_INVALID_VALUE. +is returned and @error is set to %G_KEY_FILE_ERROR_INVALID_VALUE. Since: 2.6 @@ -24666,9 +25151,9 @@ Returns the values associated with @key under @group_name as booleans. If @key cannot be found then %NULL is returned and @error is set to -#G_KEY_FILE_ERROR_KEY_NOT_FOUND. Likewise, if the values associated +%G_KEY_FILE_ERROR_KEY_NOT_FOUND. Likewise, if the values associated with @key cannot be interpreted as booleans then %NULL is returned -and @error is set to #G_KEY_FILE_ERROR_INVALID_VALUE. +and @error is set to %G_KEY_FILE_ERROR_INVALID_VALUE. Since: 2.6 @@ -24746,9 +25231,9 @@ Returns the value associated with @key under @group_name as a double. If @group_name is %NULL, the start_group is used. If @key cannot be found then 0.0 is returned and @error is set to -#G_KEY_FILE_ERROR_KEY_NOT_FOUND. Likewise, if the value associated +%G_KEY_FILE_ERROR_KEY_NOT_FOUND. Likewise, if the value associated with @key cannot be interpreted as a double then 0.0 is returned -and @error is set to #G_KEY_FILE_ERROR_INVALID_VALUE. +and @error is set to %G_KEY_FILE_ERROR_INVALID_VALUE. Since: 2.12 @@ -24783,9 +25268,9 @@ Returns the values associated with @key under @group_name as doubles. If @key cannot be found then %NULL is returned and @error is set to -#G_KEY_FILE_ERROR_KEY_NOT_FOUND. Likewise, if the values associated +%G_KEY_FILE_ERROR_KEY_NOT_FOUND. Likewise, if the values associated with @key cannot be interpreted as doubles then %NULL is returned -and @error is set to #G_KEY_FILE_ERROR_INVALID_VALUE. +and @error is set to %G_KEY_FILE_ERROR_INVALID_VALUE. Since: 2.12 @@ -24883,10 +25368,10 @@ Returns the value associated with @key under @group_name as an integer. If @key cannot be found then 0 is returned and @error is set to -#G_KEY_FILE_ERROR_KEY_NOT_FOUND. Likewise, if the value associated +%G_KEY_FILE_ERROR_KEY_NOT_FOUND. Likewise, if the value associated with @key cannot be interpreted as an integer, or is out of range for a #gint, then 0 is returned -and @error is set to #G_KEY_FILE_ERROR_INVALID_VALUE. +and @error is set to %G_KEY_FILE_ERROR_INVALID_VALUE. Since: 2.6 @@ -24921,10 +25406,10 @@ Returns the values associated with @key under @group_name as integers. If @key cannot be found then %NULL is returned and @error is set to -#G_KEY_FILE_ERROR_KEY_NOT_FOUND. Likewise, if the values associated +%G_KEY_FILE_ERROR_KEY_NOT_FOUND. Likewise, if the values associated with @key cannot be interpreted as integers, or are out of range for #gint, then %NULL is returned -and @error is set to #G_KEY_FILE_ERROR_INVALID_VALUE. +and @error is set to %G_KEY_FILE_ERROR_INVALID_VALUE. Since: 2.6 @@ -24965,7 +25450,7 @@ Returns all keys for the group name @group_name. The array of returned keys will be %NULL-terminated, so @length may optionally be %NULL. In the event that the @group_name cannot be found, %NULL is returned and @error is set to -#G_KEY_FILE_ERROR_GROUP_NOT_FOUND. +%G_KEY_FILE_ERROR_GROUP_NOT_FOUND. Since: 2.6 @@ -25044,7 +25529,7 @@ the lifetime of the #GKeyFile, it must be loaded with %G_KEY_FILE_KEEP_TRANSLATIONS in order to load strings for all locales. If @key cannot be found then %NULL is returned and @error is set -to #G_KEY_FILE_ERROR_KEY_NOT_FOUND. If the value associated +to %G_KEY_FILE_ERROR_KEY_NOT_FOUND. If the value associated with @key cannot be interpreted or no suitable translation can be found then the untranslated value is returned. @@ -25090,7 +25575,7 @@ the lifetime of the #GKeyFile, it must be loaded with %G_KEY_FILE_KEEP_TRANSLATIONS in order to load strings for all locales. If @key cannot be found then %NULL is returned and @error is set -to #G_KEY_FILE_ERROR_KEY_NOT_FOUND. If the values associated +to %G_KEY_FILE_ERROR_KEY_NOT_FOUND. If the values associated with @key cannot be interpreted or no suitable translations can be found then the untranslated values are returned. The returned array is %NULL-terminated, so @length may optionally @@ -25157,9 +25642,9 @@ Unlike g_key_file_get_value(), this function handles escape sequences like \s. In the event the key cannot be found, %NULL is returned and -@error is set to #G_KEY_FILE_ERROR_KEY_NOT_FOUND. In the +@error is set to %G_KEY_FILE_ERROR_KEY_NOT_FOUND. In the event that the @group_name cannot be found, %NULL is returned -and @error is set to #G_KEY_FILE_ERROR_GROUP_NOT_FOUND. +and @error is set to %G_KEY_FILE_ERROR_GROUP_NOT_FOUND. Since: 2.6 @@ -25193,9 +25678,9 @@ key cannot be found. Returns the values associated with @key under @group_name. In the event the key cannot be found, %NULL is returned and -@error is set to #G_KEY_FILE_ERROR_KEY_NOT_FOUND. In the +@error is set to %G_KEY_FILE_ERROR_KEY_NOT_FOUND. In the event that the @group_name cannot be found, %NULL is returned -and @error is set to #G_KEY_FILE_ERROR_GROUP_NOT_FOUND. +and @error is set to %G_KEY_FILE_ERROR_GROUP_NOT_FOUND. Since: 2.6 @@ -25268,9 +25753,9 @@ Returns the raw value associated with @key under @group_name. Use g_key_file_get_string() to retrieve an unescaped UTF-8 string. In the event the key cannot be found, %NULL is returned and -@error is set to #G_KEY_FILE_ERROR_KEY_NOT_FOUND. In the +@error is set to %G_KEY_FILE_ERROR_KEY_NOT_FOUND. In the event that the @group_name cannot be found, %NULL is returned -and @error is set to #G_KEY_FILE_ERROR_GROUP_NOT_FOUND. +and @error is set to %G_KEY_FILE_ERROR_GROUP_NOT_FOUND. Since: 2.6 @@ -27326,6 +27811,27 @@ default "" application domain <return></return> </function> +<function name="g_log_get_debug_enabled"> +<description> +Return whether debug output from the GLib logging system is enabled. + +Note that this should not be used to conditionalise calls to g_debug() or +other logging functions; it should only be used from %GLogWriterFunc +implementations. + +Note also that the value of this does not depend on `G_MESSAGES_DEBUG`; see +the docs for g_log_set_debug_enabled(). + +Since: 2.72 + +</description> +<parameters> +</parameters> +<return> %TRUE if debug output is enabled, %FALSE otherwise + +</return> +</function> + <function name="g_log_remove_handler"> <description> Removes the log handler. @@ -27380,6 +27886,27 @@ of error which is to be fatal </return> </function> +<function name="g_log_set_debug_enabled"> +<description> +Enable or disable debug output from the GLib logging system for all domains. +This value interacts disjunctively with `G_MESSAGES_DEBUG` — if either of +them would allow a debug message to be outputted, it will be. + +Note that this should not be used from within library code to enable debug +output — it is intended for external use. + +Since: 2.72 + +</description> +<parameters> +<parameter name="enabled"> +<parameter_description> %TRUE to enable debug output, %FALSE otherwise +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_log_set_default_handler"> <description> Installs a default log handler which is used if no @@ -27730,7 +28257,7 @@ The only mandatory item in the @fields dictionary is the "MESSAGE" whi contain the text shown to the user. The values in the @fields dictionary are likely to be of type String -(#G_VARIANT_TYPE_STRING). Array of bytes (#G_VARIANT_TYPE_BYTESTRING) is also +(%G_VARIANT_TYPE_STRING). Array of bytes (%G_VARIANT_TYPE_BYTESTRING) is also supported. In this case the message is handled as binary and will be forwarded to the log writer as such. The size of the array should not be higher than %G_MAXSSIZE. Otherwise it will be truncated to this size. For other types @@ -28512,6 +29039,25 @@ Creates a new #GMainContext structure. </return> </function> +<function name="g_main_context_new_with_flags"> +<description> +Creates a new #GMainContext structure. + +Since: 2.72 + +</description> +<parameters> +<parameter name="flags"> +<parameter_description> a bitwise-OR combination of #GMainContextFlags flags that can only be +set at creation time. +</parameter_description> +</parameter> +</parameters> +<return> the new #GMainContext + +</return> +</function> + <function name="g_main_context_pending"> <description> Checks if any sources have pending events for the given context. @@ -29481,7 +30027,7 @@ atomically (e.g. using g_file_set_contents()). If @filename is the name of an empty, regular file, the function will successfully return an empty #GMappedFile. In other cases of size 0 (e.g. device files such as /dev/null), @error will be set -to the #GFileError value #G_FILE_ERROR_INVAL. +to the #GFileError value %G_FILE_ERROR_INVAL. Since: 2.8 @@ -30174,7 +30720,7 @@ references and escape sequences expanded. References refer to the last match done with @string against @regex and have the same syntax used by g_regex_replace(). -The @string_to_expand must be UTF-8 encoded even if #G_REGEX_RAW was +The @string_to_expand must be UTF-8 encoded even if %G_REGEX_RAW was passed to g_regex_new(). The backreferences are extracted from the string passed to the match @@ -30494,19 +31040,19 @@ check that what has been typed so far is potentially valid, it is able to raise an error as soon as a mistake is made. GRegex supports the concept of partial matching by means of the -#G_REGEX_MATCH_PARTIAL_SOFT and #G_REGEX_MATCH_PARTIAL_HARD flags. +%G_REGEX_MATCH_PARTIAL_SOFT and %G_REGEX_MATCH_PARTIAL_HARD flags. When they are used, the return code for g_regex_match() or g_regex_match_full() is, as usual, %TRUE for a complete match, %FALSE otherwise. But, when these functions return %FALSE, you can check if the match was partial calling g_match_info_is_partial_match(). -The difference between #G_REGEX_MATCH_PARTIAL_SOFT and -#G_REGEX_MATCH_PARTIAL_HARD is that when a partial match is encountered -with #G_REGEX_MATCH_PARTIAL_SOFT, matching continues to search for a -possible complete match, while with #G_REGEX_MATCH_PARTIAL_HARD matching +The difference between %G_REGEX_MATCH_PARTIAL_SOFT and +%G_REGEX_MATCH_PARTIAL_HARD is that when a partial match is encountered +with %G_REGEX_MATCH_PARTIAL_SOFT, matching continues to search for a +possible complete match, while with %G_REGEX_MATCH_PARTIAL_HARD matching stops at the partial match. -When both #G_REGEX_MATCH_PARTIAL_SOFT and #G_REGEX_MATCH_PARTIAL_HARD +When both %G_REGEX_MATCH_PARTIAL_SOFT and %G_REGEX_MATCH_PARTIAL_HARD are set, the latter takes precedence. There were formerly some restrictions on the pattern for partial matching. @@ -31092,7 +31638,7 @@ First of all g_module_open_full() tries to open @file_name as a module. If that fails and @file_name has the ".la"-suffix (and is a libtool archive) it tries to open the corresponding module. If that fails and it doesn't have the proper module suffix for the platform -(#G_MODULE_SUFFIX), this suffix will be appended and the corresponding +(%G_MODULE_SUFFIX), this suffix will be appended and the corresponding module will be opened. If that fails and @file_name doesn't have the ".la"-suffix, this suffix is appended and g_module_open_full() tries to open the corresponding module. If eventually that fails as well, %NULL is @@ -31137,7 +31683,7 @@ Checks if modules are supported on the current platform. <function name="g_module_symbol"> <description> Gets a symbol pointer from a module, such as one exported -by #G_MODULE_EXPORT. Note that a valid symbol can be %NULL. +by %G_MODULE_EXPORT. Note that a valid symbol can be %NULL. </description> @@ -31465,6 +32011,29 @@ vulnerability. </return> </function> +<function name="g_newa0"> +<description> +Wraps g_alloca0() in a more typesafe manner. + +Since: 2.72 + +</description> +<parameters> +<parameter name="struct_type"> +<parameter_description> the type of the elements to allocate. +</parameter_description> +</parameter> +<parameter name="n_structs"> +<parameter_description> the number of elements to allocate. +</parameter_description> +</parameter> +</parameters> +<return> Pointer to stack space for @n_structs +chunks of type @struct_type + +</return> +</function> + <function name="g_node_append"> <description> Inserts a #GNode as the last child of the given parent. @@ -33242,7 +33811,7 @@ Since: 2.10 <description> Creates a new instance of a #GObject subtype and sets its properties. -Construction parameters (see #G_PARAM_CONSTRUCT, #G_PARAM_CONSTRUCT_ONLY) +Construction parameters (see %G_PARAM_CONSTRUCT, %G_PARAM_CONSTRUCT_ONLY) which are not explicitly specified are set to their default values. Any private data for the object is guaranteed to be initialized with zeros, as per g_type_create_instance(). @@ -33261,6 +33830,12 @@ make use of the %G_GINT64_CONSTANT or %G_GUINT64_CONSTANT macros. Similarly, #gfloat is promoted to #gdouble, so you must ensure that the value you provide is a #gdouble, even for a property of type #gfloat. +Since GLib 2.72, all #GObjects are guaranteed to be aligned to at least the +alignment of the largest basic GLib type (typically this is #guint64 or +#gdouble). If you need larger alignment for an element in a #GObject, you +should allocate it on the heap (aligned), or arrange for your #GObject to be +appropriately padded. + </description> <parameters> @@ -33287,7 +33862,7 @@ name/value pairs, followed by %NULL <description> Creates a new instance of a #GObject subtype and sets its properties. -Construction parameters (see #G_PARAM_CONSTRUCT, #G_PARAM_CONSTRUCT_ONLY) +Construction parameters (see %G_PARAM_CONSTRUCT, %G_PARAM_CONSTRUCT_ONLY) which are not explicitly specified are set to their default values. @@ -33351,7 +33926,7 @@ Since: 2.54 <description> Creates a new instance of a #GObject subtype and sets its properties. -Construction parameters (see #G_PARAM_CONSTRUCT, #G_PARAM_CONSTRUCT_ONLY) +Construction parameters (see %G_PARAM_CONSTRUCT, %G_PARAM_CONSTRUCT_ONLY) which are not explicitly specified are set to their default values. Deprecated: 2.54: Use g_object_new_with_properties() instead. @@ -34638,7 +35213,7 @@ Creates a new option context. The @parameter_string can serve multiple purposes. It can be used to add descriptions for "rest" arguments, which are not parsed by the #GOptionContext, typically something like "FILES" or -"FILE1 FILE2...". If you are using #G_OPTION_REMAINING for +"FILE1 FILE2...". If you are using %G_OPTION_REMAINING for collecting "rest" arguments, GLib handles this automatically by using the @arg_description of the corresponding #GOptionEntry in the usage summary. @@ -35766,7 +36341,7 @@ e.g. a tooltip. The @nick and @blurb should ideally be localized. </description> <parameters> <parameter name="param_type"> -<parameter_description> the #GType for the property; must be derived from #G_TYPE_PARAM +<parameter_description> the #GType for the property; must be derived from %G_TYPE_PARAM </parameter_description> </parameter> <parameter name="name"> @@ -36593,7 +37168,7 @@ use as the default value, or %NULL <function name="g_param_type_register_static"> <description> Registers @name as the name of a new static type derived -from #G_TYPE_PARAM. +from %G_TYPE_PARAM. The type system uses the information contained in the #GParamSpecTypeInfo structure pointed to by @info to manage the #GParamSpec type and its @@ -36795,8 +37370,8 @@ separator is returned. If @file_name is empty, it gets ".". </parameter_description> </parameter> </parameters> -<return> a newly allocated string containing the last -component of the filename +<return> a newly allocated string +containing the last component of the filename </return> </function> @@ -38762,7 +39337,7 @@ contains @data, or -1 if no element in @queue contains @data <description> A statically-allocated #GQueue must be initialized with this function before it can be used. Alternatively you can initialize it with -#G_QUEUE_INIT. It is not necessary to initialize queues created with +%G_QUEUE_INIT. It is not necessary to initialize queues created with g_queue_new(). Since: 2.14 @@ -40798,7 +41373,7 @@ Note that the DFA algorithm is slower than the standard one and it is not able to capture substrings, so backreferences do not work. Setting @start_position differs from just passing over a shortened -string and setting #G_REGEX_MATCH_NOTBOL in the case of a pattern +string and setting %G_REGEX_MATCH_NOTBOL in the case of a pattern that begins with any kind of lookbehind assertion, such as "\b". Unless %G_REGEX_RAW is specified in the options, @string must be valid UTF-8. @@ -40860,7 +41435,7 @@ when the @regex structure was created, letting you have more flexibility in reusing #GRegex structures. Setting @start_position differs from just passing over a shortened -string and setting #G_REGEX_MATCH_NOTBOL in the case of a pattern +string and setting %G_REGEX_MATCH_NOTBOL in the case of a pattern that begins with any kind of lookbehind assertion, such as "\b". Unless %G_REGEX_RAW is specified in the options, @string must be valid UTF-8. @@ -41055,12 +41630,12 @@ There are also escapes that changes the case of the following text: If you do not need to use backreferences use g_regex_replace_literal(). -The @replacement string must be UTF-8 encoded even if #G_REGEX_RAW was +The @replacement string must be UTF-8 encoded even if %G_REGEX_RAW was passed to g_regex_new(). If you want to use not UTF-8 encoded strings you can use g_regex_replace_literal(). Setting @start_position differs from just passing over a shortened -string and setting #G_REGEX_MATCH_NOTBOL in the case of a pattern that +string and setting %G_REGEX_MATCH_NOTBOL in the case of a pattern that begins with any kind of lookbehind assertion, such as "\b". Since: 2.14 @@ -41107,7 +41682,7 @@ Replaces occurrences of the pattern in regex with the output of @eval for that occurrence. Setting @start_position differs from just passing over a shortened -string and setting #G_REGEX_MATCH_NOTBOL in the case of a pattern +string and setting %G_REGEX_MATCH_NOTBOL in the case of a pattern that begins with any kind of lookbehind assertion, such as "\b". The following example uses g_regex_replace_eval() to replace multiple @@ -41198,7 +41773,7 @@ replacement text. @replacement is replaced literally, to include backreferences use g_regex_replace(). Setting @start_position differs from just passing over a -shortened string and setting #G_REGEX_MATCH_NOTBOL in the +shortened string and setting %G_REGEX_MATCH_NOTBOL in the case of a pattern that begins with any kind of lookbehind assertion, such as "\b". @@ -41304,7 +41879,7 @@ For example splitting "ab c" using as a separator "\s*", you "a", "b" and "c". Setting @start_position differs from just passing over a shortened -string and setting #G_REGEX_MATCH_NOTBOL in the case of a pattern +string and setting %G_REGEX_MATCH_NOTBOL in the case of a pattern that begins with any kind of lookbehind assertion, such as "\b". Since: 2.14 @@ -43931,7 +44506,9 @@ gdk_init(), which is called by gtk_init() and the #GtkApplication::startup handler. The program name is found by taking the last component of @argv[0]. -Note that for thread-safety reasons this function can only be called once. +Since GLib 2.72, this function can be called multiple times +and is fully thread safe. Prior to GLib 2.72, this function +could only be called once per process. </description> <parameters> @@ -44095,6 +44672,11 @@ they are passed through literally. Possible errors are those from the %G_SHELL_ERROR domain. +In particular, if @command_line is an empty string (or a string containing +only whitespace), %G_SHELL_ERROR_EMPTY_STRING will be returned. It’s +guaranteed that @argvp will be a non-empty array if this function returns +successfully. + Free the returned vector with g_strfreev(). @@ -44272,7 +44854,7 @@ Since: 2.4 <description> Adds an emission hook for a signal, which will get called for any emission of that signal, independent of the instance. This is possible only -for signals which don't have #G_SIGNAL_NO_HOOKS flag set. +for signals which don't have %G_SIGNAL_NO_HOOKS flag set. </description> @@ -44344,7 +44926,7 @@ emitted on. <parameter name="Varargs"> <parameter_description> parameters to be passed to the parent class closure, followed by a location for the return value. If the return type of the signal -is #G_TYPE_NONE, the return value location can be omitted. +is %G_TYPE_NONE, the return value location can be omitted. </parameter_description> </parameter> </parameters> @@ -44355,7 +44937,7 @@ is #G_TYPE_NONE, the return value location can be omitted. <description> Connects a #GCallback function to a signal for a particular object. -The handler will be called before the default handler of the signal. +The handler will be called synchronously, before the default handler of the signal. g_signal_emit() will not return control until all handlers are called. See [memory management of signal handlers][signal-memory-management] for details on how to handle the return value and memory management of @data. @@ -44388,7 +44970,7 @@ details on how to handle the return value and memory management of @data. <description> Connects a #GCallback function to a signal for a particular object. -The handler will be called after the default handler of the signal. +The handler will be called synchronously, after the default handler of the signal. </description> @@ -44611,7 +45193,8 @@ g_signal_connect (button, "clicked", <function name="g_signal_emit"> <description> -Emits a signal. +Emits a signal. Signal emission is done synchronously. +The method will only return control after all handlers are called or signal emission was stopped. Note that g_signal_emit() resets the return value to the default if no handlers are connected, in contrast to g_signal_emitv(). @@ -44633,7 +45216,7 @@ if no handlers are connected, in contrast to g_signal_emitv(). <parameter name="Varargs"> <parameter_description> parameters to be passed to the signal, followed by a location for the return value. If the return type of the signal -is #G_TYPE_NONE, the return value location can be omitted. +is %G_TYPE_NONE, the return value location can be omitted. </parameter_description> </parameter> </parameters> @@ -44642,7 +45225,8 @@ is #G_TYPE_NONE, the return value location can be omitted. <function name="g_signal_emit_by_name"> <description> -Emits a signal. +Emits a signal. Signal emission is done synchronously. +The method will only return control after all handlers are called or signal emission was stopped. Note that g_signal_emit_by_name() resets the return value to the default if no handlers are connected, in contrast to g_signal_emitv(). @@ -44670,7 +45254,8 @@ number of parameters to pass to this function is defined when creating the signa <function name="g_signal_emit_valist"> <description> -Emits a signal. +Emits a signal. Signal emission is done synchronously. +The method will only return control after all handlers are called or signal emission was stopped. Note that g_signal_emit_valist() resets the return value to the default if no handlers are connected, in contrast to g_signal_emitv(). @@ -44693,7 +45278,7 @@ emitted on. <parameter name="var_args"> <parameter_description> a list of parameters to be passed to the signal, followed by a location for the return value. If the return type of the signal -is #G_TYPE_NONE, the return value location can be omitted. +is %G_TYPE_NONE, the return value location can be omitted. </parameter_description> </parameter> </parameters> @@ -44702,7 +45287,8 @@ is #G_TYPE_NONE, the return value location can be omitted. <function name="g_signal_emitv"> <description> -Emits a signal. +Emits a signal. Signal emission is done synchronously. +The method will only return control after all handlers are called or signal emission was stopped. Note that g_signal_emitv() doesn't change @return_value if no handlers are connected, in contrast to g_signal_emit() and g_signal_emit_valist(). @@ -44750,6 +45336,282 @@ signal emission, or %NULL if not found. </return> </function> +<function name="g_signal_group_block"> +<description> +Blocks all signal handlers managed by @self so they will not +be called during any signal emissions. Must be unblocked exactly +the same number of times it has been blocked to become active again. + +This blocked state will be kept across changes of the target instance. + +Since: 2.72 + +</description> +<parameters> +<parameter name="self"> +<parameter_description> the #GSignalGroup +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + +<function name="g_signal_group_connect"> +<description> +Connects @c_handler to the signal @detailed_signal +on the target instance of @self. + +You cannot connect a signal handler after #GSignalGroup:target has been set. + +Since: 2.72 + +</description> +<parameters> +<parameter name="self"> +<parameter_description> a #GSignalGroup +</parameter_description> +</parameter> +<parameter name="detailed_signal"> +<parameter_description> a string of the form "signal-name::detail" +</parameter_description> +</parameter> +<parameter name="c_handler"> +<parameter_description> the #GCallback to connect +</parameter_description> +</parameter> +<parameter name="data"> +<parameter_description> the data to pass to @c_handler calls +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + +<function name="g_signal_group_connect_after"> +<description> +Connects @c_handler to the signal @detailed_signal +on the target instance of @self. + +The @c_handler will be called after the default handler of the signal. + +You cannot connect a signal handler after #GSignalGroup:target has been set. + +Since: 2.72 + +</description> +<parameters> +<parameter name="self"> +<parameter_description> a #GSignalGroup +</parameter_description> +</parameter> +<parameter name="detailed_signal"> +<parameter_description> a string of the form "signal-name::detail" +</parameter_description> +</parameter> +<parameter name="c_handler"> +<parameter_description> the #GCallback to connect +</parameter_description> +</parameter> +<parameter name="data"> +<parameter_description> the data to pass to @c_handler calls +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + +<function name="g_signal_group_connect_data"> +<description> +Connects @c_handler to the signal @detailed_signal +on the target instance of @self. + +You cannot connect a signal handler after #GSignalGroup:target has been set. + +Since: 2.72 + +</description> +<parameters> +<parameter name="self"> +<parameter_description> a #GSignalGroup +</parameter_description> +</parameter> +<parameter name="detailed_signal"> +<parameter_description> a string of the form "signal-name::detail" +</parameter_description> +</parameter> +<parameter name="c_handler"> +<parameter_description> the #GCallback to connect +</parameter_description> +</parameter> +<parameter name="data"> +<parameter_description> the data to pass to @c_handler calls +</parameter_description> +</parameter> +<parameter name="notify"> +<parameter_description> function to be called when disposing of @self +</parameter_description> +</parameter> +<parameter name="flags"> +<parameter_description> the flags used to create the signal connection +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + +<function name="g_signal_group_connect_object"> +<description> +Connects @c_handler to the signal @detailed_signal on #GSignalGroup:target. + +Ensures that the @object stays alive during the call to @c_handler +by temporarily adding a reference count. When the @object is destroyed +the signal handler will automatically be removed. + +You cannot connect a signal handler after #GSignalGroup:target has been set. + +Since: 2.72 + +</description> +<parameters> +<parameter name="self"> +<parameter_description> a #GSignalGroup +</parameter_description> +</parameter> +<parameter name="detailed_signal"> +<parameter_description> a string of the form `signal-name` with optional `::signal-detail` +</parameter_description> +</parameter> +<parameter name="c_handler"> +<parameter_description> the #GCallback to connect +</parameter_description> +</parameter> +<parameter name="object"> +<parameter_description> the #GObject to pass as data to @c_handler calls +</parameter_description> +</parameter> +<parameter name="flags"> +<parameter_description> #GConnectFlags for the signal connection +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + +<function name="g_signal_group_connect_swapped"> +<description> +Connects @c_handler to the signal @detailed_signal +on the target instance of @self. + +The instance on which the signal is emitted and @data +will be swapped when calling @c_handler. + +You cannot connect a signal handler after #GSignalGroup:target has been set. + +Since: 2.72 + +</description> +<parameters> +<parameter name="self"> +<parameter_description> a #GSignalGroup +</parameter_description> +</parameter> +<parameter name="detailed_signal"> +<parameter_description> a string of the form "signal-name::detail" +</parameter_description> +</parameter> +<parameter name="c_handler"> +<parameter_description> the #GCallback to connect +</parameter_description> +</parameter> +<parameter name="data"> +<parameter_description> the data to pass to @c_handler calls +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + +<function name="g_signal_group_dup_target"> +<description> +Gets the target instance used when connecting signals. + +Since: 2.72 + +</description> +<parameters> +<parameter name="self"> +<parameter_description> the #GSignalGroup +</parameter_description> +</parameter> +</parameters> +<return> The target instance + +</return> +</function> + +<function name="g_signal_group_new"> +<description> +Creates a new #GSignalGroup for target instances of @target_type. + +Since: 2.72 + +</description> +<parameters> +<parameter name="target_type"> +<parameter_description> the #GType of the target instance. +</parameter_description> +</parameter> +</parameters> +<return> a new #GSignalGroup + +</return> +</function> + +<function name="g_signal_group_set_target"> +<description> +Sets the target instance used when connecting signals. Any signal +that has been registered with g_signal_group_connect_object() or +similar functions will be connected to this object. + +If the target instance was previously set, signals will be +disconnected from that object prior to connecting to @target. + +Since: 2.72 + +</description> +<parameters> +<parameter name="self"> +<parameter_description> the #GSignalGroup. +</parameter_description> +</parameter> +<parameter name="target"> +<parameter_description> The target instance used +when connecting signals. +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + +<function name="g_signal_group_unblock"> +<description> +Unblocks all signal handlers managed by @self so they will be +called again during any signal emissions unless it is blocked +again. Must be unblocked exactly the same number of times it +has been blocked to become active again. + +Since: 2.72 + +</description> +<parameters> +<parameter name="self"> +<parameter_description> the #GSignalGroup +</parameter_description> +</parameter> +</parameters> +<return></return> +</function> + <function name="g_signal_handler_block"> <description> Blocks a handler of an instance so it will not be called during any @@ -45347,7 +46209,7 @@ values to signal emissions into C language callback invocations or %NULL. </parameter_description> </parameter> <parameter name="return_type"> -<parameter_description> the type of return value, or #G_TYPE_NONE for a signal +<parameter_description> the type of return value, or %G_TYPE_NONE for a signal without a return value. </parameter_description> </parameter> @@ -45422,7 +46284,7 @@ values to signal emissions into C language callback invocations or %NULL. </parameter_description> </parameter> <parameter name="return_type"> -<parameter_description> the type of return value, or #G_TYPE_NONE for a signal +<parameter_description> the type of return value, or %G_TYPE_NONE for a signal without a return value. </parameter_description> </parameter> @@ -45485,7 +46347,7 @@ values to signal emissions into C language callback invocations or %NULL. </parameter_description> </parameter> <parameter name="return_type"> -<parameter_description> the type of return value, or #G_TYPE_NONE for a signal +<parameter_description> the type of return value, or %G_TYPE_NONE for a signal without a return value. </parameter_description> </parameter> @@ -45549,7 +46411,7 @@ invocations or %NULL </parameter_description> </parameter> <parameter name="return_type"> -<parameter_description> the type of return value, or #G_TYPE_NONE for a signal +<parameter_description> the type of return value, or %G_TYPE_NONE for a signal without a return value </parameter_description> </parameter> @@ -47517,7 +48379,7 @@ wrong source. </parameter_description> </parameter> </parameters> -<return> For historical reasons, this function always returns %TRUE +<return> %TRUE if the source was found and removed. </return> </function> @@ -48112,7 +48974,8 @@ Since: 2.58 </parameter_description> </parameter> <parameter name="argv"> -<parameter_description> child's argument vector, in the GLib file name encoding +<parameter_description> child's argument vector, in the GLib file name encoding; +it must be non-empty and %NULL-terminated </parameter_description> </parameter> <parameter name="envp"> @@ -48172,7 +49035,7 @@ directory, or %NULL to inherit parent's, in the GLib file name encoding </parameter> <parameter name="argv"> <parameter_description> child's argument -vector, in the GLib file name encoding +vector, in the GLib file name encoding; it must be non-empty and %NULL-terminated </parameter_description> </parameter> <parameter name="envp"> @@ -48325,6 +49188,8 @@ to the spawned process. FD remappings are processed after standard FDs, so any target FDs which equal @stdin_fd, @stdout_fd or @stderr_fd will overwrite them in the spawned process. +@source_fds is supported on Windows since 2.72. + %G_SPAWN_FILE_AND_ARGV_ZERO means that the first element of @argv is the file to execute, while the remaining elements are the actual argument vector to pass to the file. Normally g_spawn_async_with_pipes() @@ -48377,7 +49242,7 @@ If an error is set, the function returns %FALSE. Errors are reported even if they occur in the child (for example if the executable in `@argv[0]` is not found). Typically the `message` field of returned errors should be displayed to users. Possible errors are those from -the #G_SPAWN_ERROR domain. +the %G_SPAWN_ERROR domain. If an error occurs, @child_pid, @stdin_pipe_out, @stdout_pipe_out, and @stderr_pipe_out will not be filled with valid values. @@ -48418,7 +49283,7 @@ directory, or %NULL to inherit parent's, in the GLib file name encoding </parameter> <parameter name="argv"> <parameter_description> child's argument -vector, in the GLib file name encoding +vector, in the GLib file name encoding; it must be non-empty and %NULL-terminated </parameter_description> </parameter> <parameter name="envp"> @@ -48726,7 +49591,7 @@ directory, or %NULL to inherit parent's </parameter> <parameter name="argv"> <parameter_description> -child's argument vector +child's argument vector, which must be non-empty and %NULL-terminated </parameter_description> </parameter> <parameter name="envp"> @@ -48895,7 +49760,7 @@ Deprecated: 2.32: Just use a #GMutex <function name="g_static_mutex_init"> <description> Initializes @mutex. -Alternatively you can initialize it with #G_STATIC_MUTEX_INIT. +Alternatively you can initialize it with %G_STATIC_MUTEX_INIT. Deprecated: 2.32: Use g_mutex_init() @@ -48999,7 +49864,7 @@ This function works even if g_thread_init() has not yet been called. <function name="g_static_private_init"> <description> Initializes @private_key. Alternatively you can initialize it with -#G_STATIC_PRIVATE_INIT. +%G_STATIC_PRIVATE_INIT. </description> <parameters> @@ -49069,7 +49934,7 @@ Deprecated: 2.32: Use g_rec_mutex_clear() <description> A #GStaticRecMutex must be initialized with this function before it can be used. Alternatively you can initialize it with -#G_STATIC_REC_MUTEX_INIT. +%G_STATIC_REC_MUTEX_INIT. Deprecated: 2.32: Use g_rec_mutex_init() @@ -49215,7 +50080,7 @@ Deprecated: 2.32: Use a #GRWLock instead <description> A #GStaticRWLock must be initialized with this function before it can be used. Alternatively you can initialize it with -#G_STATIC_RW_LOCK_INIT. +%G_STATIC_RW_LOCK_INIT. Deprecated: 2.32: Use g_rw_lock_init() instead @@ -49935,7 +50800,7 @@ g_free (reformatted); </parameter> <parameter name="delimiters"> <parameter_description> a string containing the current delimiters, -or %NULL to use the standard delimiters defined in #G_STR_DELIMITERS +or %NULL to use the standard delimiters defined in %G_STR_DELIMITERS </parameter_description> </parameter> <parameter name="new_delimiter"> @@ -52448,9 +53313,9 @@ Since: 2.38 Gets the pathname to a data file that is required for a test. This is the same as g_test_build_filename() with two differences. -The first difference is that must only use this function from within +The first difference is that you must only use this function from within a testcase function. The second difference is that you need not free -the return value -- it will be automatically freed when the testcase +the return value — it will be automatically freed when the testcase finishes running. It is safe to use this function from a thread inside of a testcase @@ -53297,14 +54162,15 @@ can be used to change this. <function name="g_test_timer_elapsed"> <description> -Get the time since the last start of the timer with g_test_timer_start(). +Get the number of seconds since the last start of the timer with +g_test_timer_start(). Since: 2.16 </description> <parameters> </parameters> -<return> the time since the last start of the timer, as a double +<return> the time since the last start of the timer in seconds, as a double </return> </function> @@ -54935,6 +55801,11 @@ in seconds. This is equivalent to calling g_time_zone_new() with a string in the form `[+|-]hh[:mm[:ss]]`. +It is possible for this function to fail if @seconds is too big (greater than +24 hours), in which case this function will return the UTC timezone for +backwards compatibility. To detect failures like this, use +g_time_zone_new_identifier() directly. + Since: 2.58 </description> @@ -54944,7 +55815,8 @@ Since: 2.58 </parameter_description> </parameter> </parameters> -<return> a timezone at the given offset from UTC +<return> a timezone at the given offset from UTC, or UTC on +failure </return> </function> @@ -57879,7 +58751,7 @@ instances (if not abstract). The value of @flags determines the nature </parameter_description> </parameter> </parameters> -<return> the new type identifier or #G_TYPE_INVALID if registration failed +<return> the new type identifier or %G_TYPE_INVALID if registration failed </return> </function> @@ -59341,7 +60213,7 @@ Since: 2.30 <parameters> <parameter name="priority"> <parameter_description> the priority of the signal source. Typically this will be in -the range between #G_PRIORITY_DEFAULT and #G_PRIORITY_HIGH. +the range between %G_PRIORITY_DEFAULT and %G_PRIORITY_HIGH. </parameter_description> </parameter> <parameter name="signum"> @@ -60793,7 +61665,7 @@ Since: 2.66 Pauses the current thread for the given number of microseconds. There are 1 million microseconds per second (represented by the -#G_USEC_PER_SEC macro). g_usleep() may have limited precision, +%G_USEC_PER_SEC macro). g_usleep() may have limited precision, depending on hardware and operating system; don't rely on the exact length of the sleep. @@ -60883,12 +61755,13 @@ If @len < 0, then the string is nul-terminated. words read, or %NULL. If %NULL, then %G_CONVERT_ERROR_PARTIAL_INPUT will be returned in case @str contains a trailing partial character. If an error occurs then the index of the invalid input is stored here. +It’s guaranteed to be non-negative. </parameter_description> </parameter> <parameter name="items_written"> <parameter_description> location to store number of bytes written, or %NULL. The value stored here does not include the -trailing 0 byte. +trailing 0 byte. It’s guaranteed to be non-negative. </parameter_description> </parameter> <parameter name="error"> @@ -60944,6 +61817,10 @@ faster to obtain collation keys with g_utf8_collate_key() and compare the keys with strcmp() when sorting instead of sorting the original strings. +If the two strings are not comparable due to being in different collation +sequences, the result is undefined. This can happen if the strings are in +different language scripts, for example. + </description> <parameters> @@ -61515,6 +62392,9 @@ converted to uppercase. Copies a substring out of a UTF-8 encoded string. The substring will contain @end_pos - @start_pos characters. +Since GLib 2.72, `-1` can be passed to @end_pos to indicate the +end of the string. + Since: 2.30 </description> @@ -61528,7 +62408,8 @@ Since: 2.30 </parameter_description> </parameter> <parameter name="end_pos"> -<parameter_description> another character offset within @str +<parameter_description> another character offset within @str, +or `-1` to indicate the end of the string </parameter_description> </parameter> </parameters> @@ -67749,7 +68630,8 @@ Since: 2.4 </description> <parameters> <parameter name="string"> -<parameter_description> the return location for the newly-allocated string. +<parameter_description> the return location for the newly-allocated string, +which will be %NULL if (and only if) this function fails </parameter_description> </parameter> <parameter name="format"> @@ -67762,7 +68644,7 @@ Since: 2.4 </parameter_description> </parameter> </parameters> -<return> the number of bytes printed. +<return> the number of bytes printed, or `-1` on failure </return> </function> @@ -68295,6 +69177,59 @@ deallocated with g_free(). </return> </function> +<function name="g_win32_find_helper_executable_path"> +<description> +Find an external executable path and name starting in the same folder +as a specified DLL or current process executable path. Helper executables +(like gspawn-win64-helper.exe, gspawn-win64-helper-console.exe or +gdbus.exe for example) are generally installed in the same folder as the +corresponding DLL file. + +So, if package has been correctly installed, with a dynamic build of GLib, +the helper executable should be in the same directory as the corresponding +DLL file and searching should be straightforward. + +But if built statically, DLL handle is not available and we have to start +searching from the directory holding current executable. It may be very +different from the directory containing the helper program. In order to +find the right helper program automatically in all common situations, we +use this pattern: + +current directory +|-- ??? +|-- bin +| |-- ??? +|-- lib +| |-- ??? +|-- glib +| |-- ??? +|-- gio +|-- ??? + +starting at base searching path (DLL or current executable directory) and +getting up until the root path. If we cannot still find the helper program, +we'll rely on PATH as the last resort. + + +</description> +<parameters> +<parameter name="executable_name"> +<parameter_description> name of the helper executable to find +(something like gspawn-win64-helper.exe or gdbus.exe for example). +</parameter_description> +</parameter> +<parameter name="dll_handle"> +<parameter_description> handle of the DLL to use as searching base path. Pass NULL +to take current process executable as searching base path. +</parameter_description> +</parameter> +</parameters> +<return> the helper executable +path and name in the GLib filename encoding or NULL in case of error. It +should be deallocated with g_free(). +</return> +</function> + <function name="g_win32_get_command_line"> <description> Gets the command line arguments, on Windows, in the GLib filename @@ -68661,7 +69596,7 @@ Corresponds to the standard C char type. <function name="gchararray"> <description> -A C representable type name for #G_TYPE_STRING. +A C representable type name for %G_TYPE_STRING. </description> <parameters> @@ -68686,7 +69621,7 @@ that the data pointed to will not be altered by the function. <function name="gdouble"> <description> Corresponds to the standard C double type. -Values of this type can range from -#G_MAXDOUBLE to #G_MAXDOUBLE. +Values of this type can range from -%G_MAXDOUBLE to %G_MAXDOUBLE. </description> <parameters> @@ -68697,7 +69632,7 @@ Values of this type can range from -#G_MAXDOUBLE to #G_MAXDOUBLE. <function name="gfloat"> <description> Corresponds to the standard C float type. -Values of this type can range from -#G_MAXFLOAT to #G_MAXFLOAT. +Values of this type can range from -%G_MAXFLOAT to %G_MAXFLOAT. </description> <parameters> @@ -68708,7 +69643,7 @@ Values of this type can range from -#G_MAXFLOAT to #G_MAXFLOAT. <function name="gint"> <description> Corresponds to the standard C int type. -Values of this type can range from #G_MININT to #G_MAXINT. +Values of this type can range from %G_MININT to %G_MAXINT. </description> <parameters> @@ -68719,8 +69654,8 @@ Values of this type can range from #G_MININT to #G_MAXINT. <function name="gint16"> <description> A signed integer guaranteed to be 16 bits on all platforms. -Values of this type can range from #G_MININT16 (= -32,768) to -#G_MAXINT16 (= 32,767). +Values of this type can range from %G_MININT16 (= -32,768) to +%G_MAXINT16 (= 32,767). To print or scan values of this type, use %G_GINT16_MODIFIER and/or %G_GINT16_FORMAT. @@ -68734,8 +69669,8 @@ To print or scan values of this type, use <function name="gint32"> <description> A signed integer guaranteed to be 32 bits on all platforms. -Values of this type can range from #G_MININT32 (= -2,147,483,648) -to #G_MAXINT32 (= 2,147,483,647). +Values of this type can range from %G_MININT32 (= -2,147,483,648) +to %G_MAXINT32 (= 2,147,483,647). To print or scan values of this type, use %G_GINT32_MODIFIER and/or %G_GINT32_FORMAT. @@ -68749,8 +69684,8 @@ To print or scan values of this type, use <function name="gint64"> <description> A signed integer guaranteed to be 64 bits on all platforms. -Values of this type can range from #G_MININT64 -(= -9,223,372,036,854,775,808) to #G_MAXINT64 +Values of this type can range from %G_MININT64 +(= -9,223,372,036,854,775,808) to %G_MAXINT64 (= 9,223,372,036,854,775,807). To print or scan values of this type, use @@ -68765,8 +69700,8 @@ To print or scan values of this type, use <function name="gint8"> <description> A signed integer guaranteed to be 8 bits on all platforms. -Values of this type can range from #G_MININT8 (= -128) to -#G_MAXINT8 (= 127). +Values of this type can range from %G_MININT8 (= -128) to +%G_MAXINT8 (= 127). </description> <parameters> @@ -68975,7 +69910,7 @@ by a \004 character <function name="glong"> <description> Corresponds to the standard C long type. -Values of this type can range from #G_MINLONG to #G_MAXLONG. +Values of this type can range from %G_MINLONG to %G_MAXLONG. </description> <parameters> @@ -68989,8 +69924,8 @@ A signed integer type that is used for file offsets, corresponding to the POSIX type `off_t` as if compiling with `_FILE_OFFSET_BITS` set to 64. #goffset is always 64 bits wide, even on 32-bit architectures. -Values of this type can range from #G_MINOFFSET to -#G_MAXOFFSET. +Values of this type can range from %G_MINOFFSET to +%G_MAXOFFSET. To print or scan values of this type, use %G_GOFFSET_MODIFIER and/or %G_GOFFSET_FORMAT. @@ -69039,7 +69974,7 @@ Since: 2.58 <function name="gshort"> <description> Corresponds to the standard C short type. -Values of this type can range from #G_MINSHORT to #G_MAXSHORT. +Values of this type can range from %G_MINSHORT to %G_MAXSHORT. </description> <parameters> @@ -69054,7 +69989,7 @@ corresponding to the size_t type defined in C99. This type is wide enough to hold the numeric value of a pointer, so it is usually 32 bit wide on a 32-bit platform and 64 bit wide on a 64-bit platform. Values of this type can range from 0 to -#G_MAXSIZE. +%G_MAXSIZE. To print or scan values of this type, use %G_GSIZE_MODIFIER and/or %G_GSIZE_FORMAT. @@ -69069,8 +70004,8 @@ To print or scan values of this type, use <description> A signed variant of #gsize, corresponding to the ssize_t defined on most platforms. -Values of this type can range from #G_MINSSIZE -to #G_MAXSSIZE. +Values of this type can range from %G_MINSSIZE +to %G_MAXSSIZE. To print or scan values of this type, use %G_GSSIZE_MODIFIER and/or %G_GSSIZE_FORMAT. @@ -69094,7 +70029,7 @@ Corresponds to the standard C unsigned char type. <function name="guint"> <description> Corresponds to the standard C unsigned int type. -Values of this type can range from 0 to #G_MAXUINT. +Values of this type can range from 0 to %G_MAXUINT. </description> <parameters> @@ -69105,7 +70040,7 @@ Values of this type can range from 0 to #G_MAXUINT. <function name="guint16"> <description> An unsigned integer guaranteed to be 16 bits on all platforms. -Values of this type can range from 0 to #G_MAXUINT16 (= 65,535). +Values of this type can range from 0 to %G_MAXUINT16 (= 65,535). To print or scan values of this type, use %G_GINT16_MODIFIER and/or %G_GUINT16_FORMAT. @@ -69119,7 +70054,7 @@ To print or scan values of this type, use <function name="guint32"> <description> An unsigned integer guaranteed to be 32 bits on all platforms. -Values of this type can range from 0 to #G_MAXUINT32 (= 4,294,967,295). +Values of this type can range from 0 to %G_MAXUINT32 (= 4,294,967,295). To print or scan values of this type, use %G_GINT32_MODIFIER and/or %G_GUINT32_FORMAT. @@ -69133,7 +70068,7 @@ To print or scan values of this type, use <function name="guint64"> <description> An unsigned integer guaranteed to be 64-bits on all platforms. -Values of this type can range from 0 to #G_MAXUINT64 +Values of this type can range from 0 to %G_MAXUINT64 (= 18,446,744,073,709,551,615). To print or scan values of this type, use @@ -69148,7 +70083,7 @@ To print or scan values of this type, use <function name="guint8"> <description> An unsigned integer guaranteed to be 8 bits on all platforms. -Values of this type can range from 0 to #G_MAXUINT8 (= 255). +Values of this type can range from 0 to %G_MAXUINT8 (= 255). </description> <parameters> @@ -69175,7 +70110,7 @@ Since: 2.18 <function name="gulong"> <description> Corresponds to the standard C unsigned long type. -Values of this type can range from 0 to #G_MAXULONG. +Values of this type can range from 0 to %G_MAXULONG. </description> <parameters> @@ -69239,7 +70174,7 @@ To print/scan values of this type as integer, use <function name="gushort"> <description> Corresponds to the standard C unsigned short type. -Values of this type can range from 0 to #G_MAXUSHORT. +Values of this type can range from 0 to %G_MAXUSHORT. </description> <parameters> diff --git a/glib/src/glib_enums.defs b/glib/src/glib_enums.defs index 417fdbab..50195788 100644 --- a/glib/src/glib_enums.defs +++ b/glib/src/glib_enums.defs @@ -512,6 +512,22 @@ ) ) +;; Original typedef: +;; typedef enum /*< flags >*/ +;; { +;; G_MAIN_CONTEXT_FLAGS_NONE = 0, +;; G_MAIN_CONTEXT_FLAGS_OWNERLESS_POLLING = 1 +;; } GMainContextFlags; + +(define-flags-extended MainContextFlags + (in-module "G") + (c-name "GMainContextFlags") + (values + '("none" "G_MAIN_CONTEXT_FLAGS_NONE" "0x0") + '("ownerless-polling" "G_MAIN_CONTEXT_FLAGS_OWNERLESS_POLLING" "0x1") + ) +) + ;; From gmarkup.h ;; Original typedef: @@ -1794,7 +1810,17 @@ ;; G_UNICODE_SCRIPT_CHORASMIAN, /* Chrs */ ;; G_UNICODE_SCRIPT_DIVES_AKURU, /* Diak */ ;; G_UNICODE_SCRIPT_KHITAN_SMALL_SCRIPT, /* Kits */ -;; G_UNICODE_SCRIPT_YEZIDI /* Yezi */ +;; G_UNICODE_SCRIPT_YEZIDI, /* Yezi */ +;; +;; /* Unicode 14.0 additions */ +;; G_UNICODE_SCRIPT_CYPRO_MINOAN, /* Cpmn */ +;; G_UNICODE_SCRIPT_OLD_UYGHUR, /* Ougr */ +;; G_UNICODE_SCRIPT_TANGSA, /* Tnsa */ +;; G_UNICODE_SCRIPT_TOTO, /* Toto */ +;; G_UNICODE_SCRIPT_VITHKUQI, /* Vith */ +;; +;; /* not really a Unicode script, but part of ISO 15924 */ +;; G_UNICODE_SCRIPT_MATH, /* Zmth */ ;; } GUnicodeScript; (define-enum-extended UnicodeScript @@ -1959,6 +1985,12 @@ '("dives-akuru" "G_UNICODE_SCRIPT_DIVES_AKURU" "154") '("khitan-small-script" "G_UNICODE_SCRIPT_KHITAN_SMALL_SCRIPT" "155") '("yezidi" "G_UNICODE_SCRIPT_YEZIDI" "156") + '("cypro-minoan" "G_UNICODE_SCRIPT_CYPRO_MINOAN" "157") + '("old-uyghur" "G_UNICODE_SCRIPT_OLD_UYGHUR" "158") + '("tangsa" "G_UNICODE_SCRIPT_TANGSA" "159") + '("toto" "G_UNICODE_SCRIPT_TOTO" "160") + '("vithkuqi" "G_UNICODE_SCRIPT_VITHKUQI" "161") + '("math" "G_UNICODE_SCRIPT_MATH" "162") ) ) diff --git a/glib/src/glib_functions.defs b/glib/src/glib_functions.defs index 7e209657..4963b298 100644 --- a/glib/src/glib_functions.defs +++ b/glib/src/glib_functions.defs @@ -282,6 +282,16 @@ ) ) +(define-enum ContextFlags + (in-module "GMain") + (c-name "GMainContextFlags") + (gtype-id "G_TYPE_MAIN_CONTEXT_FLAGS") + (values + '("none" "G_MAIN_CONTEXT_FLAGS_NONE") + '("ownerless-polling" "G_MAIN_CONTEXT_FLAGS_OWNERLESS_POLLING") + ) +) + (define-enum Error (in-module "GMarkup") (c-name "GMarkupError") @@ -999,6 +1009,12 @@ '("dives-akuru" "G_UNICODE_SCRIPT_DIVES_AKURU") '("khitan-small-script" "G_UNICODE_SCRIPT_KHITAN_SMALL_SCRIPT") '("yezidi" "G_UNICODE_SCRIPT_YEZIDI") + '("cypro-minoan" "G_UNICODE_SCRIPT_CYPRO_MINOAN") + '("old-uyghur" "G_UNICODE_SCRIPT_OLD_UYGHUR") + '("tangsa" "G_UNICODE_SCRIPT_TANGSA") + '("toto" "G_UNICODE_SCRIPT_TOTO") + '("vithkuqi" "G_UNICODE_SCRIPT_VITHKUQI") + '("math" "G_UNICODE_SCRIPT_MATH") ) ) @@ -4832,6 +4848,12 @@ ) ) +(define-method new_similar + (of-object "GHashTable") + (c-name "g_hash_table_new_similar") + (return-type "GHashTable*") +) + (define-method destroy (of-object "GHashTable") (c-name "g_hash_table_destroy") @@ -6531,6 +6553,15 @@ (return-type "none") ) +(define-function g_win32_find_helper_executable_path + (c-name "g_win32_find_helper_executable_path") + (return-type "gchar*") + (parameters + '("const-gchar*" "process_name") + '("void*" "dll_handle") + ) +) + ;; From glibintl.h @@ -6958,6 +6989,14 @@ (return-type "GMainContext*") ) +(define-function g_main_context_new_with_flags + (c-name "g_main_context_new_with_flags") + (return-type "GMainContext*") + (parameters + '("GMainContextFlags" "flags") + ) +) + (define-method ref (of-object "GMainContext") (c-name "g_main_context_ref") @@ -7999,6 +8038,34 @@ ) ) +(define-function g_aligned_alloc + (c-name "g_aligned_alloc") + (return-type "gpointer") + (parameters + '("gsize" "n_blocks") + '("gsize" "n_block_bytes") + '("gsize" "alignment") + ) +) + +(define-function g_aligned_alloc0 + (c-name "g_aligned_alloc0") + (return-type "gpointer") + (parameters + '("gsize" "n_blocks") + '("gsize" "n_block_bytes") + '("gsize" "alignment") + ) +) + +(define-function g_aligned_free + (c-name "g_aligned_free") + (return-type "none") + (parameters + '("gpointer" "mem") + ) +) + (define-function g_mem_set_vtable (c-name "g_mem_set_vtable") (return-type "none") @@ -8238,6 +8305,19 @@ ) ) +(define-function g_log_get_debug_enabled + (c-name "g_log_get_debug_enabled") + (return-type "gboolean") +) + +(define-function g_log_set_debug_enabled + (c-name "g_log_set_debug_enabled") + (return-type "none") + (parameters + '("gboolean" "enabled") + ) +) + (define-function g_return_if_fail_warning (c-name "g_return_if_fail_warning") (return-type "none") @@ -14744,6 +14824,11 @@ (return-type "const-gchar*") ) +(define-function g_get_user_state_dir + (c-name "g_get_user_state_dir") + (return-type "const-gchar*") +) + (define-function g_get_system_data_dirs (c-name "g_get_system_data_dirs") (return-type "const-gchar*-const*") diff --git a/glib/src/gobject_functions.defs b/glib/src/gobject_functions.defs index d28ee7f5..68baccb1 100644 --- a/glib/src/gobject_functions.defs +++ b/glib/src/gobject_functions.defs @@ -130,6 +130,78 @@ +;; From gbindinggroup.h + +(define-function g_binding_group_get_type + (c-name "g_binding_group_get_type") + (return-type "GType") +) + +(define-function g_binding_group_new + (c-name "g_binding_group_new") + (is-constructor-of "GBindingGroup") + (return-type "GBindingGroup*") +) + +(define-method dup_source + (of-object "GBindingGroup") + (c-name "g_binding_group_dup_source") + (return-type "gpointer") +) + +(define-method set_source + (of-object "GBindingGroup") + (c-name "g_binding_group_set_source") + (return-type "none") + (parameters + '("gpointer" "source") + ) +) + +(define-method bind + (of-object "GBindingGroup") + (c-name "g_binding_group_bind") + (return-type "none") + (parameters + '("const-gchar*" "source_property") + '("gpointer" "target") + '("const-gchar*" "target_property") + '("GBindingFlags" "flags") + ) +) + +(define-method bind_full + (of-object "GBindingGroup") + (c-name "g_binding_group_bind_full") + (return-type "none") + (parameters + '("const-gchar*" "source_property") + '("gpointer" "target") + '("const-gchar*" "target_property") + '("GBindingFlags" "flags") + '("GBindingTransformFunc" "transform_to") + '("GBindingTransformFunc" "transform_from") + '("gpointer" "user_data") + '("GDestroyNotify" "user_data_destroy") + ) +) + +(define-method bind_with_closures + (of-object "GBindingGroup") + (c-name "g_binding_group_bind_with_closures") + (return-type "none") + (parameters + '("const-gchar*" "source_property") + '("gpointer" "target") + '("const-gchar*" "target_property") + '("GBindingFlags" "flags") + '("GClosure*" "transform_to") + '("GClosure*" "transform_from") + ) +) + + + ;; From gbinding.h (define-function g_binding_flags_get_type @@ -2624,6 +2696,109 @@ +;; From gsignalgroup.h + +(define-function g_signal_group_get_type + (c-name "g_signal_group_get_type") + (return-type "GType") +) + +(define-function g_signal_group_new + (c-name "g_signal_group_new") + (is-constructor-of "GSignalGroup") + (return-type "GSignalGroup*") + (parameters + '("GType" "target_type") + ) +) + +(define-method set_target + (of-object "GSignalGroup") + (c-name "g_signal_group_set_target") + (return-type "none") + (parameters + '("gpointer" "target") + ) +) + +(define-method dup_target + (of-object "GSignalGroup") + (c-name "g_signal_group_dup_target") + (return-type "gpointer") +) + +(define-method block + (of-object "GSignalGroup") + (c-name "g_signal_group_block") + (return-type "none") +) + +(define-method unblock + (of-object "GSignalGroup") + (c-name "g_signal_group_unblock") + (return-type "none") +) + +(define-method connect_object + (of-object "GSignalGroup") + (c-name "g_signal_group_connect_object") + (return-type "none") + (parameters + '("const-gchar*" "detailed_signal") + '("GCallback" "c_handler") + '("gpointer" "object") + '("GConnectFlags" "flags") + ) +) + +(define-method connect_data + (of-object "GSignalGroup") + (c-name "g_signal_group_connect_data") + (return-type "none") + (parameters + '("const-gchar*" "detailed_signal") + '("GCallback" "c_handler") + '("gpointer" "data") + '("GClosureNotify" "notify") + '("GConnectFlags" "flags") + ) +) + +(define-method connect + (of-object "GSignalGroup") + (c-name "g_signal_group_connect") + (return-type "none") + (parameters + '("const-gchar*" "detailed_signal") + '("GCallback" "c_handler") + '("gpointer" "data") + ) +) + +(define-method connect_after + (of-object "GSignalGroup") + (c-name "g_signal_group_connect_after") + (return-type "none") + (parameters + '("const-gchar*" "detailed_signal") + '("GCallback" "c_handler") + '("gpointer" "data") + ) +) + +(define-method connect_swapped + (of-object "GSignalGroup") + (c-name "g_signal_group_connect_swapped") + (return-type "none") + (parameters + '("const-gchar*" "detailed_signal") + '("GCallback" "c_handler") + '("gpointer" "data") + ) +) + + + ;; From gsignal.h (define-function g_signal_newv |