[glib] GObject: Convert docs to markdown



commit 60b623d3fb70c09cb08e6c088b76c59d4316e132
Author: Matthias Clasen <mclasen redhat com>
Date:   Sat Feb 1 10:19:07 2014 -0500

    GObject: Convert docs to markdown
    
    In particular, convert lists to markdown syntax.

 gobject/gclosure.c    |   27 +++++++-----------
 gobject/gobject.c     |   65 +++++---------------------------------------
 gobject/gsignal.c     |   29 ++++++++-----------
 gobject/gtypemodule.c |   30 +++++++--------------
 gobject/gtypeplugin.c |   71 +++++++++++++++++++++---------------------------
 5 files changed, 72 insertions(+), 150 deletions(-)
---
diff --git a/gobject/gclosure.c b/gobject/gclosure.c
index 9cc6464..4ec51ef 100644
--- a/gobject/gclosure.c
+++ b/gobject/gclosure.c
@@ -71,22 +71,17 @@
  *
  * Using closures has a number of important advantages over a simple
  * callback function/data pointer combination:
- * <itemizedlist>
- * <listitem><para>
- * Closures allow the callee to get the types of the callback parameters,
- * which means that language bindings don't have to write individual glue
- * for each callback type.
- * </para></listitem>
- * <listitem><para>
- * The reference counting of #GClosure makes it easy to handle reentrancy
- * right; if a callback is removed while it is being invoked, the closure
- * and its parameters won't be freed until the invocation finishes.
- * </para></listitem>
- * <listitem><para>
- * g_closure_invalidate() and invalidation notifiers allow callbacks to be
- * automatically removed when the objects they point to go away.
- * </para></listitem>
- * </itemizedlist>
+ * 
+ * - Closures allow the callee to get the types of the callback parameters,
+ *   which means that language bindings don't have to write individual glue
+ *   for each callback type.
+ *
+ * - The reference counting of #GClosure makes it easy to handle reentrancy
+ *   right; if a callback is removed while it is being invoked, the closure
+ *   and its parameters won't be freed until the invocation finishes.
+ *
+ * - g_closure_invalidate() and invalidation notifiers allow callbacks to be
+ *   automatically removed when the objects they point to go away.
  */
 
 #define        CLOSURE_MAX_REF_COUNT           ((1 << 15) - 1)
diff --git a/gobject/gobject.c b/gobject/gobject.c
index 258f996..b404a9d 100644
--- a/gobject/gobject.c
+++ b/gobject/gobject.c
@@ -2399,63 +2399,14 @@ g_object_get_property (GObject     *object,
  *
  * The signal specs expected by this function have the form
  * "modifier::signal_name", where modifier can be one of the following:
- * <variablelist>
- * <varlistentry>
- * <term>signal</term>
- * <listitem><para>
- * equivalent to <literal>g_signal_connect_data (..., NULL, 0)</literal>
- * </para></listitem>
- * </varlistentry>
- * <varlistentry>
- * <term>object_signal</term>
- * <term>object-signal</term>
- * <listitem><para>
- * equivalent to <literal>g_signal_connect_object (..., 0)</literal>
- * </para></listitem>
- * </varlistentry>
- * <varlistentry>
- * <term>swapped_signal</term>
- * <term>swapped-signal</term>
- * <listitem><para>
- * equivalent to <literal>g_signal_connect_data (..., NULL, G_CONNECT_SWAPPED)</literal>
- * </para></listitem>
- * </varlistentry>
- * <varlistentry>
- * <term>swapped_object_signal</term>
- * <term>swapped-object-signal</term>
- * <listitem><para>
- * equivalent to <literal>g_signal_connect_object (..., G_CONNECT_SWAPPED)</literal>
- * </para></listitem>
- * </varlistentry>
- * <varlistentry>
- * <term>signal_after</term>
- * <term>signal-after</term>
- * <listitem><para>
- * equivalent to <literal>g_signal_connect_data (..., NULL, G_CONNECT_AFTER)</literal>
- * </para></listitem>
- * </varlistentry>
- * <varlistentry>
- * <term>object_signal_after</term>
- * <term>object-signal-after</term>
- * <listitem><para>
- * equivalent to <literal>g_signal_connect_object (..., G_CONNECT_AFTER)</literal>
- * </para></listitem>
- * </varlistentry>
- * <varlistentry>
- * <term>swapped_signal_after</term>
- * <term>swapped-signal-after</term>
- * <listitem><para>
- * equivalent to <literal>g_signal_connect_data (..., NULL, G_CONNECT_SWAPPED | G_CONNECT_AFTER)</literal>
- * </para></listitem>
- * </varlistentry>
- * <varlistentry>
- * <term>swapped_object_signal_after</term>
- * <term>swapped-object-signal-after</term>
- * <listitem><para>
- * equivalent to <literal>g_signal_connect_object (..., G_CONNECT_SWAPPED | G_CONNECT_AFTER)</literal>
- * </para></listitem>
- * </varlistentry>
- * </variablelist>
+ * * - signal: equivalent to g_signal_connect_data (..., NULL, 0)
+ * - object-signal, object_signal: equivalent to g_signal_connect_object (..., 0)
+ * - swapped-signal, swapped_signal: equivalent to g_signal_connect_data (..., NULL, G_CONNECT_SWAPPED)
+ * - swapped_object_signal, swapped-object-signal: equivalent to g_signal_connect_object (..., 
G_CONNECT_SWAPPED)
+ * - signal_after, signal-after: equivalent to g_signal_connect_data (..., NULL, G_CONNECT_AFTER)
+ * - object_signal_after, object-signal-after: equivalent to g_signal_connect_object (..., G_CONNECT_AFTER)
+ * - swapped_signal_after, swapped-signal-after: equivalent to g_signal_connect_data (..., NULL, 
G_CONNECT_SWAPPED | G_CONNECT_AFTER)
+ * - swapped_object_signal_after, swapped-object-signal-after: equivalent to g_signal_connect_object (..., 
G_CONNECT_SWAPPED | G_CONNECT_AFTER)
  *
  * |[
  *   menu->toplevel = g_object_connect (g_object_new (GTK_TYPE_WINDOW,
diff --git a/gobject/gsignal.c b/gobject/gsignal.c
index 8115022..2110d09 100644
--- a/gobject/gsignal.c
+++ b/gobject/gsignal.c
@@ -65,23 +65,18 @@
  * certain signal on certain object instances.
  *
  * A signal emission consists of five stages, unless prematurely stopped:
- * <variablelist>
- * <varlistentry><term></term><listitem><para>
- *     1 - Invocation of the object method handler for %G_SIGNAL_RUN_FIRST signals
- * </para></listitem></varlistentry>
- * <varlistentry><term></term><listitem><para>
- *     2 - Invocation of normal user-provided signal handlers (where the @after flag is not set)
- * </para></listitem></varlistentry>
- * <varlistentry><term></term><listitem><para>
- *     3 - Invocation of the object method handler for %G_SIGNAL_RUN_LAST signals
- * </para></listitem></varlistentry>
- * <varlistentry><term></term><listitem><para>
- *     4 - Invocation of user provided signal handlers (where the @after flag is set)
- * </para></listitem></varlistentry>
- * <varlistentry><term></term><listitem><para>
- *     5 - Invocation of the object method handler for %G_SIGNAL_RUN_CLEANUP signals
- * </para></listitem></varlistentry>
- * </variablelist>
+ *
+ * 1. Invocation of the object method handler for %G_SIGNAL_RUN_FIRST signals
+ *
+ * 2. Invocation of normal user-provided signal handlers (where the @after
+ *    flag is not set)
+ *
+ * 3. Invocation of the object method handler for %G_SIGNAL_RUN_LAST signals
+ *
+ * 4. Invocation of user provided signal handlers (where the @after flag is set)
+ *
+ * 5. Invocation of the object method handler for %G_SIGNAL_RUN_CLEANUP signals
+ 
  * The user-provided signal handlers are called in the order they were
  * connected in.
  *
diff --git a/gobject/gtypemodule.c b/gobject/gtypemodule.c
index a8d5510..35d13e2 100644
--- a/gobject/gtypemodule.c
+++ b/gobject/gtypemodule.c
@@ -26,30 +26,20 @@
 /**
  * SECTION:gtypemodule
  * @short_description: Type loading modules
- * @see_also:<variablelist>
- * <varlistentry>
- * <term>#GTypePlugin</term>
- * <listitem><para>The abstract type loader interface.</para></listitem>
- * </varlistentry>
- * <varlistentry>
- * <term>#GModule</term>
- * <listitem><para>Portable mechanism for dynamically loaded modules.</para></listitem>
- * </varlistentry>
- * </variablelist>
+ * @see_also: #GTypePlugin, #GModule
  * @title: GTypeModule
  *
  * #GTypeModule provides a simple implementation of the #GTypePlugin
  * interface. The model of #GTypeModule is a dynamically loaded module
- * which implements some number of types and interface
- * implementations. When the module is loaded, it registers its types
- * and interfaces using g_type_module_register_type() and
- * g_type_module_add_interface().  As long as any instances of these
- * types and interface implementations are in use, the module is kept
- * loaded. When the types and interfaces are gone, the module may be
- * unloaded. If the types and interfaces become used again, the module
- * will be reloaded. Note that the last unref cannot happen in module
- * code, since that would lead to the caller's code being unloaded before
- * g_object_unref() returns to it.
+ * which implements some number of types and interface implementations.
+ * When the module is loaded, it registers its types and interfaces
+ * using g_type_module_register_type() and g_type_module_add_interface().
+ * As long as any instances of these types and interface implementations
+ * are in use, the module is kept loaded. When the types and interfaces
+ * are gone, the module may be unloaded. If the types and interfaces
+ * become used again, the module will be reloaded. Note that the last
+ * unref cannot happen in module code, since that would lead to the
+ * caller's code being unloaded before g_object_unref() returns to it.
  *
  * Keeping track of whether the module should be loaded or not is done by
  * using a use count - it starts at zero, and whenever it is greater than
diff --git a/gobject/gtypeplugin.c b/gobject/gtypeplugin.c
index 13fc989..c29258c 100644
--- a/gobject/gtypeplugin.c
+++ b/gobject/gtypeplugin.c
@@ -26,49 +26,40 @@
  * @see_also: #GTypeModule and g_type_register_dynamic().
  * @title: GTypePlugin
  *
- * The GObject type system supports dynamic loading of types. The
- * #GTypePlugin interface is used to handle the lifecycle of
- * dynamically loaded types.  It goes as follows:
+ * The GObject type system supports dynamic loading of types.
+ * The #GTypePlugin interface is used to handle the lifecycle
+ * of dynamically loaded types. It goes as follows:
  *
- * <orderedlist>
- * <listitem><para>
- *   The type is initially introduced (usually upon loading the module
- *   the first time, or by your main application that knows what modules
- *   introduces what types), like this:
- *   |[
- *   new_type_id = g_type_register_dynamic (parent_type_id,
- *                                                 "TypeName",
- *                                                 new_type_plugin,
- *                                                 type_flags);
- *   ]|
- *   where <literal>new_type_plugin</literal> is an implementation of the
- *   #GTypePlugin interface.
- * </para></listitem>
- * <listitem><para>
- *    The type's implementation is referenced, e.g. through
+ * 1. The type is initially introduced (usually upon loading the module
+ *    the first time, or by your main application that knows what modules
+ *    introduces what types), like this:
+ *    |[
+ *    new_type_id = g_type_register_dynamic (parent_type_id,
+ *                                           "TypeName",
+ *                                           new_type_plugin,
+ *                                           type_flags);
+ *    ]|
+ *    where @new_type_plugin is an implementation of the
+ *    #GTypePlugin interface.
+ *
+ * 2. The type's implementation is referenced, e.g. through
  *    g_type_class_ref() or through g_type_create_instance() (this is
  *    being called by g_object_new()) or through one of the above done on
- *    a type derived from <literal>new_type_id</literal>.
- * </para></listitem>
- * <listitem><para>
- *    This causes the type system to load the type's implementation by calling
- *    g_type_plugin_use() and g_type_plugin_complete_type_info() on
- *    <literal>new_type_plugin</literal>.
- * </para></listitem>
- * <listitem><para>
- *    At some point the type's implementation isn't required anymore, e.g. after
- *    g_type_class_unref() or g_type_free_instance() (called when the reference
- *    count of an instance drops to zero).
- * </para></listitem>
- * <listitem><para>
- *    This causes the type system to throw away the information retrieved from
- *    g_type_plugin_complete_type_info() and then it calls
- *    g_type_plugin_unuse() on <literal>new_type_plugin</literal>.
- * </para></listitem>
- * <listitem><para>
- *    Things may repeat from the second step.
- * </para></listitem>
- * </orderedlist>
+ *    a type derived from @new_type_id.
+ *
+ * 3. This causes the type system to load the type's implementation by
+ *    calling g_type_plugin_use() and g_type_plugin_complete_type_info()
+ *    on @new_type_plugin.
+ * 
+ * 4. At some point the type's implementation isn't required anymore,
+ *    e.g. after g_type_class_unref() or g_type_free_instance() (called
+ *    when the reference count of an instance drops to zero).
+ *
+ * 5. This causes the type system to throw away the information retrieved
+ *    from g_type_plugin_complete_type_info() and then it calls
+ *    g_type_plugin_unuse() on @new_type_plugin.
+ * 
+ * 6. Things may repeat from the second step.
  *
  * So basically, you need to implement a #GTypePlugin type that
  * carries a use_count, once use_count goes from zero to one, you need


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