[gobject-introspection] Update glib annotations from git



commit e348fa5bf89f3da14257bd05c7801053ebeb74df
Author: Rico Tzschichholz <ricotz t-online de>
Date:   Thu May 24 08:27:36 2012 +0200

    Update glib annotations from git

 gir/gio-2.0.c     |   62 ++++++++++++++++++++++++++++++++++++++++++++++++++--
 gir/glib-2.0.c    |   27 ++++++++++++++++------
 gir/gobject-2.0.c |   21 ++++++++++++++++++
 3 files changed, 99 insertions(+), 11 deletions(-)
---
diff --git a/gir/gio-2.0.c b/gir/gio-2.0.c
index 6f7c407..84ca7ba 100644
--- a/gir/gio-2.0.c
+++ b/gir/gio-2.0.c
@@ -7733,6 +7733,12 @@
  *
  * Creates a new #GAppInfo from the given information.
  *
+ * Note that for @commandline, the quoting rules of the Exec key of the
+ * <ulink url="http://freedesktop.org/Standards/desktop-entry-spec";>freedesktop.org Desktop
+ * Entry Specification</ulink> are applied. For example, if the @commandline contains
+ * percent-encoded URIs, the percent-character must be doubled in order to prevent it from
+ * being swallowed by Exec key unquoting. See the specification for exact quoting rules.
+ *
  * Returns: (transfer full): new #GAppInfo for given command.
  */
 
@@ -7938,6 +7944,22 @@
 
 
 /**
+ * g_app_info_get_supported_types:
+ * @info: a #GAppInfo that can handle files
+ *
+ * Retrieves the list of content types that @app_info claims to support.
+ * If this information is not provided by the environment, this function
+ * will return %NULL.
+ * This function does not take in consideration associations added with
+ * g_app_info_add_supports_type(), but only those exported directly by
+ * the application.
+ *
+ * Returns: (transfer none) (array zero-terminated=1) (element-type utf8): a list of content types.
+ * Since: 2.34
+ */
+
+
+/**
  * g_app_info_launch:
  * @appinfo: a #GAppInfo
  * @files: (element-type GFile): a #GList of #GFile objects
@@ -20565,6 +20587,17 @@
 
 
 /**
+ * g_memory_input_stream_add_bytes:
+ * @stream: a #GMemoryInputStream
+ * @bytes: input data
+ *
+ * Appends @bytes to data that can be read from the input stream.
+ *
+ * Since: 2.34
+ */
+
+
+/**
  * g_memory_input_stream_add_data:
  * @stream: a #GMemoryInputStream
  * @data: (array length=len) (element-type guint8) (transfer full): input data
@@ -20585,6 +20618,17 @@
 
 
 /**
+ * g_memory_input_stream_new_from_bytes:
+ * @bytes: a #GBytes
+ *
+ * Creates a new #GMemoryInputStream with data from the given @bytes.
+ *
+ * Returns: new #GInputStream read from @bytes
+ * Since: 2.34
+ */
+
+
+/**
  * g_memory_input_stream_new_from_data:
  * @data: (array length=len) (element-type guint8) (transfer full): input data
  * @len: length of the data, may be -1 if @data is a nul-terminated string
@@ -20673,6 +20717,18 @@
 
 
 /**
+ * g_memory_output_stream_steal_as_bytes:
+ * @ostream: a #GMemoryOutputStream
+ *
+ * Returns data from the @ostream as a #GBytes. @ostream must be
+ * closed before calling this function.
+ *
+ * Returns: (transfer full): the stream's data
+ * Since: 2.34
+ */
+
+
+/**
  * g_memory_output_stream_steal_data:
  * @ostream: a #GMemoryOutputStream
  *
@@ -20709,7 +20765,7 @@
  * @detailed_action: (allow-none): the detailed action string, or %NULL
  *
  * Convenience function for appending a normal menu item to the end of
- * @menu.  Combine g_menu_new() and g_menu_insert_item() for a more
+ * @menu.  Combine g_menu_item_new() and g_menu_insert_item() for a more
  * flexible alternative.
  *
  * Since: 2.32
@@ -20855,7 +20911,7 @@
  * @detailed_action: (allow-none): the detailed action string, or %NULL
  *
  * Convenience function for inserting a normal menu item into @menu.
- * Combine g_menu_new() and g_menu_insert_item() for a more flexible
+ * Combine g_menu_item_new() and g_menu_insert_item() for a more flexible
  * alternative.
  *
  * Since: 2.32
@@ -21496,7 +21552,7 @@
  * @detailed_action: (allow-none): the detailed action string, or %NULL
  *
  * Convenience function for prepending a normal menu item to the start
- * of @menu.  Combine g_menu_new() and g_menu_insert_item() for a more
+ * of @menu.  Combine g_menu_item_new() and g_menu_insert_item() for a more
  * flexible alternative.
  *
  * Since: 2.32
diff --git a/gir/glib-2.0.c b/gir/glib-2.0.c
index 7a1754a..6c7b9f0 100644
--- a/gir/glib-2.0.c
+++ b/gir/glib-2.0.c
@@ -13662,7 +13662,7 @@
 
 /**
  * g_environ_getenv:
- * @envp: (array zero-terminated=1) (transfer none): an environment list (eg, as returned from g_get_environ())
+ * @envp: (allow-none) (array zero-terminated=1) (transfer none): an environment list (eg, as returned from g_get_environ()), or %NULL for an empty environment list
  * @variable: the environment variable to get, in the GLib file name encoding
  *
  * Returns the value of the environment variable @variable in the
@@ -13682,7 +13682,7 @@
 
 /**
  * g_environ_setenv:
- * @envp: (array zero-terminated=1) (transfer full): an environment list that can be freed using g_strfreev() (e.g., as returned from g_get_environ())
+ * @envp: (allow-none) (array zero-terminated=1) (transfer full): an environment list that can be freed using g_strfreev() (e.g., as returned from g_get_environ()), or %NULL for an empty environment list
  * @variable: the environment variable to set, must not contain '='
  * @value: the value for to set the variable to
  * @overwrite: whether to change the variable if it already exists
@@ -13701,7 +13701,7 @@
 
 /**
  * g_environ_unsetenv:
- * @envp: (array zero-terminated=1) (transfer full): an environment list that can be freed using g_strfreev() (e.g., as returned from g_get_environ())
+ * @envp: (allow-none) (array zero-terminated=1) (transfer full): an environment list that can be freed using g_strfreev() (e.g., as returned from g_get_environ()), or %NULL for an empty environment list
  * @variable: the environment variable to remove, must not contain '='
  *
  * Removes the environment variable @variable from the provided
@@ -16871,7 +16871,7 @@
 /**
  * g_key_file_load_from_data:
  * @key_file: an empty #GKeyFile struct
- * @data: key file loaded in memory
+ * @data: (length length): key file loaded in memory
  * @length: the length of @data in bytes (or -1 if data is nul-terminated)
  * @flags: flags from #GKeyFileFlags
  * @error: return location for a #GError, or %NULL
@@ -25161,8 +25161,15 @@
  * should be a %NULL-terminated array of strings, to be passed as the
  * argument vector for the child. The first string in @argv is of
  * course the name of the program to execute. By default, the name of
- * the program must be a full path; the <envar>PATH</envar> shell variable
- * will only be searched if you pass the %G_SPAWN_SEARCH_PATH flag.
+ * the program must be a full path. If @flags contains the
+ * %G_SPAWN_SEARCH_PATH flag, the <envar>PATH</envar> environment variable
+ * is used to search for the executable. If @flags contains the
+ * %G_SPAWN_SEARCH_PATH_FROM_ENVP flag, the <envar>PATH</envar> variable from
+ * @envp is used to search for the executable.
+ * If both the %G_SPAWN_SEARCH_PATH and %G_SPAWN_SEARCH_PATH_FROM_ENVP
+ * flags are set, the <envar>PATH</envar> variable from @envp takes precedence
+ * over the environment variable.
+ *
  * If the program name is not a full path and %G_SPAWN_SEARCH_PATH flag is not
  * used, then the program will be run from the current directory (or
  * @working_directory, if specified); this might be unexpected or even
@@ -25228,7 +25235,11 @@
  * descriptors except stdin/stdout/stderr will be closed before
  * calling exec() in the child. %G_SPAWN_SEARCH_PATH
  * means that <literal>argv[0]</literal> need not be an absolute path, it
- * will be looked for in the user's <envar>PATH</envar>.
+ * will be looked for in the <envar>PATH</envar> environment variable.
+ * %G_SPAWN_SEARCH_PATH_FROM_ENVP means need not be an absolute path, it
+ * will be looked for in the <envar>PATH</envar> variable from @envp. If
+ * both %G_SPAWN_SEARCH_PATH and %G_SPAWN_SEARCH_PATH_FROM_ENVP are used,
+ * the value from @envp takes precedence over the environment.
  * %G_SPAWN_STDOUT_TO_DEV_NULL means that the child's standard output will
  * be discarded, instead of going to the same location as the parent's
  * standard output. If you use this flag, @standard_output must be %NULL.
@@ -29927,7 +29938,7 @@
 
 /**
  * g_utf8_validate:
- * @str: a pointer to character data
+ * @str: (array length=max_len) (element-type guint8): a pointer to character data
  * @max_len: max bytes to validate, or -1 to go until NUL
  * @end: (allow-none) (out): return location for end of valid data
  *
diff --git a/gir/gobject-2.0.c b/gir/gobject-2.0.c
index abbb141..03257c8 100644
--- a/gir/gobject-2.0.c
+++ b/gir/gobject-2.0.c
@@ -4377,6 +4377,27 @@
 
 
 /**
+ * g_type_ensure:
+ * @type: a #GType.
+ *
+ * Ensures that the indicated @type has been registered with the
+ * type system, and its _class_init() method has been run.
+ *
+ * In theory, simply calling the type's _get_type() method (or using
+ * the corresponding macro) is supposed take care of this. However,
+ * _get_type() methods are often marked %G_GNUC_CONST for performance
+ * reasons, even though this is technically incorrect (since
+ * %G_GNUC_CONST requires that the function not have side effects,
+ * which _get_type() methods do on the first call). As a result, if
+ * you write a bare call to a _get_type() macro, it may get optimized
+ * out by the compiler. Using g_type_ensure() guarantees that the
+ * type's _get_type() method is called.
+ *
+ * Since: 2.34
+ */
+
+
+/**
  * g_type_free_instance:
  * @instance: an instance of a type.
  *



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]