[glib] gvariant: Fix some typos in documentation
- From: Philip Withnall <pwithnall src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glib] gvariant: Fix some typos in documentation
- Date: Thu, 27 Apr 2017 14:44:26 +0000 (UTC)
commit 75cd848ea861a2278e90d8ee9810e91dc49240a6
Author: Krzesimir Nowak <krzesimir kinvolk io>
Date: Wed Apr 26 11:58:58 2017 +0200
gvariant: Fix some typos in documentation
Reformatted the docs for G_VARIANT_TYPE_UINT64 to avoid having a
number in the beginning of the line, because apparently gtk-doc treats
that as a first element of the numbered list. The number being that
big probably makes gtk-doc to treat it as 1.
Fixed the g_variant_new_fixed_array documentation - it was partially
copy-pasted from the g_variant_get_fixed_array documentation.
The rest should be quite obvious.
https://bugzilla.gnome.org/show_bug.cgi?id=781830
glib/gvariant.c | 15 +++++++--------
glib/gvarianttype.c | 2 +-
glib/gvarianttype.h | 4 ++--
3 files changed, 10 insertions(+), 11 deletions(-)
---
diff --git a/glib/gvariant.c b/glib/gvariant.c
index 7b533b8..579f569 100644
--- a/glib/gvariant.c
+++ b/glib/gvariant.c
@@ -58,10 +58,10 @@
* can use:
*
* |[<!-- language="C" -->
- * GVariant *v = g_variant_new ('u', 40);
+ * GVariant *v = g_variant_new ("u", 40);
* ]|
*
- * The string 'u' in the first argument tells #GVariant that the data passed to
+ * The string "u" in the first argument tells #GVariant that the data passed to
* the constructor (40) is going to be an unsigned integer.
*
* More advanced examples of #GVariant in use can be found in documentation for
@@ -1177,10 +1177,10 @@ g_variant_get_fixed_array (GVariant *value,
* @n_elements: the number of elements
* @element_size: the size of each element
*
- * Provides access to the serialised data for an array of fixed-sized
- * items.
+ * Constructs a new array #GVariant instance, where the elements are
+ * of @element_type type.
*
- * @value must be an array with fixed-sized elements. Numeric types are
+ * @elements must be an array with fixed-sized elements. Numeric types are
* fixed-size as are tuples containing only other fixed-sized types.
*
* @element_size must be the size of a single element in the array.
@@ -1189,8 +1189,7 @@ g_variant_get_fixed_array (GVariant *value,
* of a double-check that the form of the serialised data matches the caller's
* expectation.
*
- * @n_elements, which must be non-%NULL is set equal to the number of
- * items in the array.
+ * @n_elements must be the length of the @elements array.
*
* Returns: (transfer none): a floating reference to a new array #GVariant instance
*
@@ -5336,7 +5335,7 @@ g_variant_new (const gchar *format_string,
*
* Note that the arguments in @app must be of the correct width for their
* types specified in @format_string when collected into the #va_list.
- * See the [GVariant varargs documentation][gvariant-varargs.
+ * See the [GVariant varargs documentation][gvariant-varargs].
*
* These two generalisations allow mixing of multiple calls to
* g_variant_new_va() and g_variant_get_va() within a single actual
diff --git a/glib/gvarianttype.c b/glib/gvarianttype.c
index b8d6faa..e36c1c1 100644
--- a/glib/gvarianttype.c
+++ b/glib/gvarianttype.c
@@ -133,7 +133,7 @@
* - `s`: the type string of %G_VARIANT_TYPE_STRING; a string.
* - `o`: the type string of %G_VARIANT_TYPE_OBJECT_PATH; a string in the form
* of a D-Bus object path.
- * - `g`: the type string of %G_VARIANT_TYPE_STRING; a string in the form of
+ * - `g`: the type string of %G_VARIANT_TYPE_SIGNATURE; a string in the form of
* a D-Bus type signature.
* - `?`: the type string of %G_VARIANT_TYPE_BASIC; an indefinite type that
* is a supertype of any of the basic types.
diff --git a/glib/gvarianttype.h b/glib/gvarianttype.h
index 25db4df..b48b267 100644
--- a/glib/gvarianttype.h
+++ b/glib/gvarianttype.h
@@ -96,8 +96,8 @@ typedef struct _GVariantType GVariantType;
/**
* G_VARIANT_TYPE_UINT64:
*
- * The type of an integer value that can range from 0 to
- * 18446744073709551616. That's a really big number, but a Rubik's
+ * The type of an integer value that can range from 0
+ * to 18446744073709551616. That's a really big number, but a Rubik's
* cube can have a bit more than twice as many possible positions.
**/
#define G_VARIANT_TYPE_UINT64 ((const GVariantType *) "t")
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]