[libgsf] Fix introspection and gtk-doc warnings.



commit 3b816a0ef3064959574dc7454dffa067882b56f3
Author: Jean Brefort <jean brefort normalesup org>
Date:   Fri Jul 20 18:57:20 2012 +0200

    Fix introspection and gtk-doc warnings.

 ChangeLog                           |    3 +
 configure.in                        |    4 +-
 doc/Makefile.am                     |    4 +-
 doc/{gsf-docs.sgml => gsf-docs.xml} |   77 ++++------
 doc/gsf-sections.txt                |   19 +++
 gsf/Makefile.am                     |    2 +-
 gsf/gsf-blob.c                      |    2 +-
 gsf/gsf-clip-data.c                 |   12 +-
 gsf/gsf-doc-meta-data.c             |  133 +++++++++-------
 gsf/gsf-doc-meta-data.h             |    1 +
 gsf/gsf-docprop-vector.c            |   10 +-
 gsf/gsf-infile-ar.c                 |    2 +-
 gsf/gsf-infile-msole.c              |    4 +-
 gsf/gsf-infile-msvba.c              |   32 ++--
 gsf/gsf-infile-stdio.c              |    6 +-
 gsf/gsf-infile-tar.c                |    2 +-
 gsf/gsf-infile-zip.c                |    2 +-
 gsf/gsf-infile.c                    |   50 +++---
 gsf/gsf-input-bzip.c                |    6 +-
 gsf/gsf-input-gzip.c                |    6 +-
 gsf/gsf-input-http.c                |    6 +-
 gsf/gsf-input-iochannel.c           |    6 +-
 gsf/gsf-input-proxy.c               |   12 +-
 gsf/gsf-input-stdio.c               |   14 +-
 gsf/gsf-input-textline.c            |   12 +-
 gsf/gsf-input.c                     |   50 +++---
 gsf/gsf-libxml.c                    |  300 +++++++++++++++++++++--------------
 gsf/gsf-libxml.h                    |   11 +-
 gsf/gsf-msole-utils.c               |   94 ++++++++----
 gsf/gsf-msole-utils.h               |    1 +
 gsf/gsf-open-pkg-utils.c            |  132 +++++++++-------
 gsf/gsf-opendoc-utils.c             |   44 +++---
 gsf/gsf-opendoc-utils.h             |    5 +-
 gsf/gsf-outfile-msole.c             |   14 +-
 gsf/gsf-outfile-stdio.c             |   20 ++--
 gsf/gsf-outfile-zip.c               |    2 +-
 gsf/gsf-outfile.c                   |   34 +++--
 gsf/gsf-output-bzip.c               |    6 +-
 gsf/gsf-output-gzip.c               |    6 +-
 gsf/gsf-output-iconv.c              |    8 +-
 gsf/gsf-output-iochannel.c          |    2 +-
 gsf/gsf-output-memory.c             |    6 +-
 gsf/gsf-output-stdio.c              |   24 ++--
 gsf/gsf-output-transaction.c        |    8 +-
 gsf/gsf-output.c                    |   70 ++++----
 gsf/gsf-structured-blob.c           |    6 +-
 gsf/gsf-timestamp.c                 |   20 ++--
 gsf/gsf-utils.c                     |   58 ++++----
 gsf/gsf-zip-impl.h                  |    4 +
 gsf/gsf-zip-utils.c                 |   85 ++++++++++-
 50 files changed, 838 insertions(+), 599 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 4983813..6a8ee60 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,6 @@
+2012-07-20  Jean Brefort  <jean brefort normalesup org>
+	* all files: fix introspection and gtk-doc warnings.
+
 2012-05-22  Andreas J. Guelzow <aguelzow pyrshep ca>
 
 	* gsf/gsf-opendoc-utils.c (gsf_xml_out_add_gvalue_for_odf): new
diff --git a/configure.in b/configure.in
index 174d09d..a830360 100644
--- a/configure.in
+++ b/configure.in
@@ -307,10 +307,10 @@ AM_CONDITIONAL(CROSS_COMPILING, test x"$cross_compiling" != "xno")
 # Checks for gtk-doc and docbook-tools
 ##################################################
 gtk_doc_installed=true
-#ifdef([GTK_DOC_CHECK],[GTK_DOC_CHECK([1.0])],[gtk_doc_installed=false])
+#ifdef([GTK_DOC_CHECK],[GTK_DOC_CHECK([1.12])],[gtk_doc_installed=false])
 # I would have liked to conditionalize this, but 
 # that appears to break other things http://bugzilla.gnome.org/show_bug.cgi?id=156399
-GTK_DOC_CHECK([1.0])
+GTK_DOC_CHECK([1.12])
 AM_CONDITIONAL(GTK_DOC_INSTALLED, $gtk_doc_installed)
 
 dnl ***********************************************************************************
diff --git a/doc/Makefile.am b/doc/Makefile.am
index a91bc02..bb6b61c 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -4,7 +4,7 @@
 DOC_MODULE=gsf
 
 # The top-level SGML file.
-DOC_MAIN_SGML_FILE=gsf-docs.sgml
+DOC_MAIN_SGML_FILE=gsf-docs.xml
 
 # The directory containing the source code. Relative to $(srcdir)
 DOC_SOURCE_DIR=../gsf
@@ -16,7 +16,7 @@ SCANGOBJ_OPTIONS= --nogtkinit --type-init-func="gsf_init ()"
 SCAN_OPTIONS=
 
 # Extra options to supply to gtkdoc-mkdb
-MKDB_OPTIONS=--sgml-mode --output-format=xml
+MKDB_OPTIONS=--xml-mode --output-format=xml
 
 # Extra options to supply to gtkdoc-fixref
 FIXXREF_OPTIONS=
diff --git a/doc/gsf-docs.sgml b/doc/gsf-docs.xml
similarity index 78%
rename from doc/gsf-docs.sgml
rename to doc/gsf-docs.xml
index baf6ef6..cfcc059 100644
--- a/doc/gsf-docs.sgml
+++ b/doc/gsf-docs.xml
@@ -1,32 +1,11 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" 
-               "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd"; [
-
-<!ENTITY GsfInput		SYSTEM "xml/input.xml">
-<!ENTITY GsfOutput		SYSTEM "xml/output.xml">
-<!ENTITY GsfInfile		SYSTEM "xml/infile.xml">
-<!ENTITY GsfOutfile		SYSTEM "xml/outfile.xml">
-
-<!ENTITY GsfStdio		SYSTEM "xml/stdio.xml">
-<!ENTITY GsfMemory		SYSTEM "xml/memory.xml">
-<!ENTITY GsfIOChannel		SYSTEM "xml/iochannel.xml">
-<!ENTITY GsfGIO                 SYSTEM "xml/gio.xml">
-
-<!ENTITY GsfMetadata		SYSTEM "xml/metadata.xml">
-<!ENTITY GsfMsole		SYSTEM "xml/msole.xml">
-<!ENTITY GsfBlobs		SYSTEM "xml/blobs.xml">
-<!ENTITY GsfClipData		SYSTEM "xml/clip-data.xml">
-<!ENTITY GsfCompression		SYSTEM "xml/compression.xml">
-<!ENTITY GsfZip			SYSTEM "xml/zip.xml">
-<!ENTITY GsfXml			SYSTEM "xml/xml.xml">
-<!ENTITY GsfText		SYSTEM "xml/text.xml">
-<!ENTITY GsfOpenDocument	SYSTEM "xml/opendoc.xml">
-
-<!ENTITY GsfUtils		SYSTEM "xml/utils.xml">
-<!ENTITY TreeIndex		SYSTEM "xml/tree_index.sgml">
+<?xml version="1.0"?>
+<!DOCTYPE book PUBLIC '-//OASIS//DTD DocBook XML V4.5//EN'
+                      'http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd' [
+<!ENTITY % local.common.attrib "xmlns:xi  CDATA  #FIXED 'http://www.w3.org/2003/XInclude'">
+<!ENTITY version SYSTEM "version.xml">
 ]>
+<book lang="en" id="gsf" xmlns:xi="http://www.w3.org/2003/XInclude";>
 
-<book id="index">
   <bookinfo>
     <title>GSF Reference Manual</title>
   </bookinfo>
@@ -69,7 +48,7 @@ GSF depends on the following libraries:
 <variablelist>
 
 <varlistentry>
-<term><link linkend="glib" title="GLib">GLib</link></term>
+<term><link linkend="GLib" title="GLib">GLib</link></term>
 <listitem><para>
 A general-purpose utility library, not specific to graphical user interfaces.
 GLib provides many useful data types, macros, type conversions,
@@ -189,36 +168,40 @@ data and a set of parsers for various structured types of data streams.
     </partintro>
   <chapter id="io">
     <title>Basic Input/Output</title>
-    &GsfInput;
-    &GsfOutput;
+    <xi:include href="xml/input.xml"/>
+    <xi:include href="xml/output.xml"/>
   </chapter>
   <chapter id="sources">
     <title>Stream Sources</title>
-    &GsfInfile;
-    &GsfOutfile;
-    &GsfStdio;
-    &GsfMemory;
-    &GsfIOChannel;
-    &GsfGIO;
+    <xi:include href="xml/infile.xml"/>
+    <xi:include href="xml/outfile.xml"/>
+    <xi:include href="xml/stdio.xml"/>
+    <xi:include href="xml/memory.xml"/>
+    <xi:include href="xml/iochannel.xml"/>
+    <xi:include href="xml/gio.xml"/>
   </chapter>
   <chapter id="parsers">
     <title>Stream Parsers</title>
-    &GsfText;
-    &GsfXml;
-    &GsfZip;
-    &GsfCompression;
-    &GsfMsole;
-    &GsfMetadata;
-    &GsfOpenDocument;
-    &GsfBlobs;
-    &GsfClipData;
+    <xi:include href="xml/text.xml"/>
+    <xi:include href="xml/xml.xml"/>
+    <xi:include href="xml/zip.xml"/>
+    <xi:include href="xml/compression.xml"/>
+    <xi:include href="xml/msole.xml"/>
+    <xi:include href="xml/metadata.xml"/>
+    <xi:include href="xml/opendoc.xml"/>
+    <xi:include href="xml/blobs.xml"/>
+    <xi:include href="xml/clip-data.xml"/>
   </chapter>
   <chapter id="misc">
     <title>Miscellaneous</title>
-    &GsfUtils;
+    <xi:include href="xml/utils.xml"/>
   </chapter>
  </part>
 <index id="gsf-index">
-&TreeIndex;
+    <title id="index-all">Index</title>
+<xi:include href="xml/tree_index.sgml"/>
 </index>
+
+<xi:include href="xml/annotation-glossary.xml"><xi:fallback /></xi:include>
+
 </book>
diff --git a/doc/gsf-sections.txt b/doc/gsf-sections.txt
index 046b314..e0bc3fd 100644
--- a/doc/gsf-sections.txt
+++ b/doc/gsf-sections.txt
@@ -244,6 +244,10 @@ GSF_OUTPUT_BZIP_TYPE
 GSF_OUTPUT_BZIP
 GSF_IS_OUTPUT_BZIP
 gsf_output_bzip_get_type
+<SUBSECTION Private>
+gsf_zip_dirent_get_type
+gsf_zip_vdir_get_type
+gsf_zip_vdir_new
 </SECTION>
 
 <SECTION>
@@ -383,6 +387,16 @@ GsfMSOleSortingKey
 gsf_opendoc_metadata_read
 gsf_opendoc_metadata_subtree
 gsf_opendoc_metadata_write
+gsf_doc_prop_get_type
+gsf_odf_out_get_version
+gsf_odf_out_get_version_string
+<SUBSECTION Standard>
+GsfODFOut
+GSF_IS_ODF_OUT
+GSF_ODF_OUT
+GSF_ODF_OUT_TYPE
+GsfODFOutClass
+gsf_odf_out_get_type
 </SECTION>
 
 <SECTION>
@@ -669,6 +683,10 @@ GSF_INPUT_HTTP
 GSF_INPUT_HTTP_TYPE
 GSF_IS_INPUT_HTTP
 gsf_input_http_new
+GsfXMLOutClass
+<SUBSECTION Private>
+gsf_xml_in_doc_get_type
+gsf_xml_in_ns_get_type
 </SECTION>
 
 <SECTION>
@@ -855,6 +873,7 @@ GSF_DOC_META_DATA_TYPE
 GSF_DOC_META_DATA
 IS_GSF_DOC_META_DATA
 gsf_doc_meta_data_get_type
+gsf_msole_sorting_key_get_type
 
 GSF_DOCPROP_VECTOR
 GSF_DOCPROP_VECTOR_TYPE
diff --git a/gsf/Makefile.am b/gsf/Makefile.am
index f710af0..e68813d 100644
--- a/gsf/Makefile.am
+++ b/gsf/Makefile.am
@@ -7,7 +7,7 @@ include $(top_srcdir)/gsf.mk
 -include $(INTROSPECTION_MAKEFILE)
 INTROSPECTION_GIRS =
 INTROSPECTION_SCANNER_ARGS = \
-	-v
+	-v --warn-all --accept-unprefixed
 INTROSPECTION_COMPILER_ARGS = \
 	--includedir=$(srcdir) \
     --includedir=.
diff --git a/gsf/gsf-blob.c b/gsf/gsf-blob.c
index cda146a..4fc787c 100644
--- a/gsf/gsf-blob.c
+++ b/gsf/gsf-blob.c
@@ -156,7 +156,7 @@ gsf_blob_get_size (GsfBlob const *blob)
  * for you; it returns a pointer to the actual buffer which the blob uses internally,
  * so you should not free this buffer on your own.
  *
- * Return value: Pointer to the data stored in the blob, or %NULL if the size
+ * Return value: (transfer none): Pointer to the data stored in the blob, or %NULL if the size
  * of the data is zero.
  **/
 gconstpointer
diff --git a/gsf/gsf-clip-data.c b/gsf/gsf-clip-data.c
index 33a833b..5dc4204 100644
--- a/gsf/gsf-clip-data.c
+++ b/gsf/gsf-clip-data.c
@@ -126,7 +126,7 @@ gsf_clip_data_get_format (GsfClipData *clip_data)
  *
  * Queries the data blob that actually stores a #GsfClipData's binary data.
  *
- * Return value: A new reference to the #GsfBlob that stores this @clip_data's
+ * Return value: (transfer full): A new reference to the #GsfBlob that stores this @clip_data's
  * binary data.  You must use g_object_unref() to dispose of that data blob when
  * you are done with it.
  **/
@@ -186,10 +186,10 @@ get_windows_clipboard_data_offset (GsfClipFormatWindows format)
 
 /**
  * check_format_windows:
- * @format : #GsfClipFormatWindows
- * @format_name : const char *
- * @blob_size : #gsize
- * @error :#GError
+ * @format: #GsfClipFormatWindows
+ * @format_name: const char *
+ * @blob_size: #gsize
+ * @error: #GError
  *
  * Checks that the specified blob size matches the expected size for the format.
  *
@@ -291,7 +291,7 @@ gsf_clip_data_get_windows_clipboard_format (GsfClipData *clip_data, GError **err
  * bytes in front of the actual metafile data.  This function will skip over
  * those header bytes if necessary and return a pointer to the "real" data.
  *
- * Return value: Pointer to the real clipboard data.  The size in bytes of this
+ * Return value: (transfer none): Pointer to the real clipboard data.  The size in bytes of this
  * buffer is returned in the @ret_size argument.
  **/
 gconstpointer
diff --git a/gsf/gsf-doc-meta-data.c b/gsf/gsf-doc-meta-data.c
index c938a83..b8f7635 100644
--- a/gsf/gsf-doc-meta-data.c
+++ b/gsf/gsf-doc-meta-data.c
@@ -38,6 +38,7 @@ struct _GsfDocProp {
 	char   *name;
 	GValue *val;
 	char   *linked_to; /* optionally NULL */
+	unsigned ref_count;
 };
 
 static GObjectClass *parent_class;
@@ -71,9 +72,9 @@ GSF_CLASS(GsfDocMetaData, gsf_doc_meta_data,
 /**********************************************************************/
 
 /**
- * gsf_doc_meta_data_new :
+ * gsf_doc_meta_data_new:
  *
- * Returns: a new metadata property collection
+ * Returns: (transfer full): a new metadata property collection
  **/
 GsfDocMetaData *
 gsf_doc_meta_data_new (void)
@@ -82,9 +83,9 @@ gsf_doc_meta_data_new (void)
 }
 
 /**
- * gsf_doc_meta_data_lookup :
- * @meta : #GsfDocMetaData
- * @name :
+ * gsf_doc_meta_data_lookup:
+ * @meta: #GsfDocMetaData
+ * @name:
  *
  * Returns: the property with name @id in @meta.  The caller can modify the
  * property value and link but not the name.
@@ -98,10 +99,10 @@ gsf_doc_meta_data_lookup (GsfDocMetaData const *meta, char const *name)
 }
 
 /**
- * gsf_doc_meta_data_insert :
- * @meta : #GsfDocMetaData
- * @name : the id.
- * @value : #GValue
+ * gsf_doc_meta_data_insert:
+ * @meta: #GsfDocMetaData
+ * @name: the id.
+ * @value: #GValue
  *
  * Take ownership of @name and @value and insert a property into @meta.
  * If a property exists with @name, it is replaced (The link is lost)
@@ -121,9 +122,9 @@ gsf_doc_meta_data_insert (GsfDocMetaData *meta, char *name, GValue *value)
 }
 
 /**
- * gsf_doc_meta_data_remove :
- * @meta : the collection
- * @name : the non-null string name of the property
+ * gsf_doc_meta_data_remove:
+ * @meta: the collection
+ * @name: the non-null string name of the property
  *
  * If @name does not exist in the collection, do nothing. If @name does exist,
  * remove it and its value from the collection
@@ -137,9 +138,9 @@ gsf_doc_meta_data_remove (GsfDocMetaData *meta, char const *name)
 }
 
 /**
- * gsf_doc_meta_data_store :
- * @meta : #GsfDocMetaData
- * @name :
+ * gsf_doc_meta_data_steal:
+ * @meta: #GsfDocMetaData
+ * @name:
  *
  **/
 GsfDocProp *
@@ -155,9 +156,9 @@ gsf_doc_meta_data_steal (GsfDocMetaData *meta, char const *name)
 }
 
 /**
- * gsf_doc_meta_data_store :
- * @meta : #GsfDocMetaData
- * @prop : #GsfDocProp
+ * gsf_doc_meta_data_store:
+ * @meta: #GsfDocMetaData
+ * @prop: #GsfDocProp
  *
  **/
 void
@@ -183,10 +184,10 @@ deref_strcmp (const char **a, const char **b)
 }
 
 /**
- * gsf_doc_meta_data_foreach :
- * @meta : the collection
- * @func : the function called once for each element in the collection
- * @user_data : any supplied user data or %NULL
+ * gsf_doc_meta_data_foreach:
+ * @meta: the collection
+ * @func: (scope call): the function called once for each element in the collection
+ * @user_data: any supplied user data or %NULL
  *
  * Iterate through each (key, value) pair in this collection
  **/
@@ -220,8 +221,8 @@ gsf_doc_meta_data_foreach (GsfDocMetaData const *meta, GHFunc func, gpointer use
 }
 
 /**
- * gsf_doc_meta_data_size :
- * @meta : the collection
+ * gsf_doc_meta_data_size:
+ * @meta: the collection
  *
  * Returns: the number of items in this collection
  **/
@@ -246,8 +247,8 @@ cb_print_property (G_GNUC_UNUSED char const *name,
 }
 
 /**
- * gsf_doc_meta_dump :
- * @meta : #GsfDocMetaData
+ * gsf_doc_meta_dump:
+ * @meta: #GsfDocMetaData
  *
  * A debugging utility to dump the content of @meta via g_print
  **/
@@ -261,8 +262,8 @@ gsf_doc_meta_dump (GsfDocMetaData const *meta)
 /**********************************************************************/
 
 /**
- * gsf_doc_prop_new :
- * @name :
+ * gsf_doc_prop_new:
+ * @name:
  *
  * Returns: a new #GsfDocProp which the caller is responsible for freeing.
  * Takes ownership of @name.
@@ -283,8 +284,8 @@ gsf_doc_prop_new  (char *name)
 }
 
 /**
- * gsf_doc_prop_free :
- * @prop : #GsfDocProp
+ * gsf_doc_prop_free:
+ * @prop: #GsfDocProp
  *
  * If @prop is non %NULL free the memory associated with it
  **/
@@ -292,20 +293,44 @@ void
 gsf_doc_prop_free (GsfDocProp *prop)
 {
 	if (NULL != prop) {
-		g_free (prop->linked_to);
-
-		if (prop->val) {
-			g_value_unset (prop->val);
-			g_free (prop->val);
+		prop->ref_count--;
+		if (prop->ref_count == 0) {
+			g_free (prop->linked_to);
+
+			if (prop->val) {
+				g_value_unset (prop->val);
+				g_free (prop->val);
+			}
+			g_free (prop->name);
+			g_free (prop);
 		}
-		g_free (prop->name);
-		g_free (prop);
 	}
+		
+}
+
+static GsfDocProp *
+gsf_doc_prop_ref (GsfDocProp *prop) {
+	prop->ref_count++;
+	return prop;
+}
+
+GType
+gsf_doc_prop_get_type (void)
+{
+    static GType type = 0;
+
+    if (type == 0)
+	type = g_boxed_type_register_static
+	    ("GsfDocProp",
+	     (GBoxedCopyFunc) gsf_doc_prop_ref,
+	     (GBoxedFreeFunc) gsf_doc_prop_free);
+
+    return type;
 }
 
 /**
- * gsf_doc_prop_get_name :
- * @prop : #GsfDocProp
+ * gsf_doc_prop_get_name:
+ * @prop: #GsfDocProp
  *
  * Returns: the name of the property, the caller should not modify the result.
  **/
@@ -317,8 +342,8 @@ gsf_doc_prop_get_name (GsfDocProp const *prop)
 }
 
 /**
- * gsf_doc_prop_get_val :
- * @prop : the property
+ * gsf_doc_prop_get_val:
+ * @prop: the property
  *
  * Returns: the value of the property, the caller should not modify the result.
  **/
@@ -330,9 +355,9 @@ gsf_doc_prop_get_val (GsfDocProp const *prop)
 }
 
 /**
- * gsf_doc_prop_set_val :
- * @prop : #GsfDocProp
- * @val  : #GValue
+ * gsf_doc_prop_set_val:
+ * @prop: #GsfDocProp
+ * @val: #GValue
  *
  * Assigns @val to @prop, and unsets and frees the current value.
  **/
@@ -351,9 +376,9 @@ gsf_doc_prop_set_val (GsfDocProp *prop, GValue *val)
 }
 
 /**
- * gsf_doc_prop_swap_val :
- * @prop : #GsfDocProp
- * @val  : #GValue
+ * gsf_doc_prop_swap_val:
+ * @prop: #GsfDocProp
+ * @val: #GValue
  *
  * Returns: the current value of @prop, and replaces it with @val
  * 	Caller is responsible for unsetting and freeing the result.
@@ -370,8 +395,8 @@ gsf_doc_prop_swap_val (GsfDocProp *prop, GValue *val)
 }
 
 /**
- * gsf_doc_prop_get_link :
- * @prop : #GsfDocProp
+ * gsf_doc_prop_get_link:
+ * @prop: #GsfDocProp
  *
  * Returns: the current link descriptor of @prop.  The result should not be
  * 	freed or modified.
@@ -384,9 +409,9 @@ gsf_doc_prop_get_link (GsfDocProp const *prop)
 }
 
 /**
- * gsf_doc_prop_set_link :
- * @prop : #GsfDocProp
- * @link : optionally %NULL
+ * gsf_doc_prop_set_link:
+ * @prop: #GsfDocProp
+ * @link: optionally %NULL
  *
  * Sets @prop's link to @link
  **/
@@ -402,8 +427,8 @@ gsf_doc_prop_set_link (GsfDocProp *prop, char *link)
 }
 
 /**
- * gsf_doc_prop_dump :
- * @prop : #GsfDocProp
+ * gsf_doc_prop_dump:
+ * @prop: #GsfDocProp
  *
  * A debugging utility to dump @prop as text via g_print
  * New in 1.14.2
diff --git a/gsf/gsf-doc-meta-data.h b/gsf/gsf-doc-meta-data.h
index 9f1e4ed..2b996eb 100644
--- a/gsf/gsf-doc-meta-data.h
+++ b/gsf/gsf-doc-meta-data.h
@@ -52,6 +52,7 @@ void		gsf_doc_meta_data_foreach (GsfDocMetaData const *meta,
 gsize		gsf_doc_meta_data_size	  (GsfDocMetaData const *meta);
 void		gsf_doc_meta_dump	  (GsfDocMetaData const *meta);
 
+GType	      gsf_doc_prop_get_type (void);
 GsfDocProp   *gsf_doc_prop_new	    (char *name);
 void	      gsf_doc_prop_free	    (GsfDocProp *prop);
 char const   *gsf_doc_prop_get_name (GsfDocProp const *prop);
diff --git a/gsf/gsf-docprop-vector.c b/gsf/gsf-docprop-vector.c
index 57004d7..492ef59 100644
--- a/gsf/gsf-docprop-vector.c
+++ b/gsf/gsf-docprop-vector.c
@@ -45,13 +45,13 @@ gsf_value_get_docprop_varray (GValue const *value)
 }
 
 /**
- * gsf_docprop_value_get_vector
+ * gsf_value_get_docprop_vector:
  * @value: A GValue of type #GsfDocPropVector.
  *
  * This function returns a pointer to the GsfDocPropVector structure in @value.
  * No additional references are created.
  *
- * Returns: A pointer to the #GsfDocPropVector structure in @value
+ * Returns: (transfer none): A pointer to the #GsfDocPropVector structure in @value
  **/
 GsfDocPropVector *
 gsf_value_get_docprop_vector (GValue const *value)
@@ -62,7 +62,7 @@ gsf_value_get_docprop_vector (GValue const *value)
 }
 
 /**
- * gsf_docprop_vector_append
+ * gsf_docprop_vector_append:
  * @vector: The vector to which the GValue will be added
  * @value:  The GValue to add to @vector
  *
@@ -79,7 +79,7 @@ gsf_docprop_vector_append (GsfDocPropVector *vector, GValue *value)
 }
 
 /**
- * gsf_docprop_vector_as_string
+ * gsf_docprop_vector_as_string:
  * @vector: The #GsfDocPropVector from which GValues will be extracted.
  *
  * This function returns a string which represents all the GValues in @vector.
@@ -143,7 +143,7 @@ GSF_CLASS (GsfDocPropVector, gsf_docprop_vector,
 	   G_TYPE_OBJECT)
 
 /**
- * gsf_docprop_vector_new
+ * gsf_docprop_vector_new:
  *
  * This function creates a new gsf_docprop_vector object.
  *
diff --git a/gsf/gsf-infile-ar.c b/gsf/gsf-infile-ar.c
index a5584bd..6cbf07e 100644
--- a/gsf/gsf-infile-ar.c
+++ b/gsf/gsf-infile-ar.c
@@ -452,7 +452,7 @@ GSF_CLASS (GsfInfileAr, gsf_infile_ar,
 	   GSF_INFILE_TYPE)
 
 /**
- * gsf_infile_ar_new :
+ * gsf_infile_ar_new:
  * @source: #GsfInput
  * @err: #Gerror
  *
diff --git a/gsf/gsf-infile-msole.c b/gsf/gsf-infile-msole.c
index b9cd6c2..be617c0 100644
--- a/gsf/gsf-infile-msole.c
+++ b/gsf/gsf-infile-msole.c
@@ -911,7 +911,7 @@ GSF_CLASS (GsfInfileMSOle, gsf_infile_msole,
 	   GSF_INFILE_TYPE)
 
 /**
- * gsf_infile_msole_new :
+ * gsf_infile_msole_new:
  * @source: #GsfInput
  * @err: optional place to store an error
  *
@@ -947,7 +947,7 @@ gsf_infile_msole_new (GsfInput *source, GError **err)
 }
 
 /**
- * gsf_infile_msole_get_class_id :
+ * gsf_infile_msole_get_class_id:
  * @ole: a #GsfInfileMSOle
  * @res: 16 byte identifier (often a GUID in MS Windows apps)
  *
diff --git a/gsf/gsf-infile-msvba.c b/gsf/gsf-infile-msvba.c
index d00e8be..00f76a7 100644
--- a/gsf/gsf-infile-msvba.c
+++ b/gsf/gsf-infile-msvba.c
@@ -94,9 +94,9 @@ vba_extract_module_source (GsfInfileMSVBA *vba, char const *name, guint32 src_of
 }
 
 /**
- * vba_dir_read :
- * @vba : #GsfInfileMSVBA
- * @err : optionally NULL
+ * vba_dir_read:
+ * @vba: #GsfInfileMSVBA
+ * @err: optionally NULL
  *
  * Read an VBA dirctory and its project file.
  * along the way.
@@ -285,9 +285,9 @@ fail_stream :
 
 #if 0
 /**
- * vba_project_read :
- * @vba : #GsfInfileMSVBA
- * @err : optionally NULL
+ * vba_project_read:
+ * @vba: #GsfInfileMSVBA
+ * @err: optionally NULL
  *
  * Read an VBA dirctory and its project file.
  * along the way.
@@ -460,12 +460,12 @@ gsf_infile_msvba_new (GsfInfile *source, GError **err)
 }
 
 /**
- * gsf_infile_msvba_get_modules :
- * @vba_stream : #GsfInfile
+ * gsf_infile_msvba_get_modules:
+ * @vba_stream: #GsfInfile
  *
  * a collection of names and source code.
  *
- * Returns: %NULL, or a hashtable of names and source code (unknown encoding).
+ * Returns: (transfer none): %NULL, or a hashtable of names and source code (unknown encoding).
  **/
 GHashTable *
 gsf_infile_msvba_get_modules (GsfInfileMSVBA const *vba_stream)
@@ -475,12 +475,12 @@ gsf_infile_msvba_get_modules (GsfInfileMSVBA const *vba_stream)
 }
 
 /**
- * gsf_infile_msvba_steal_modules :
- * @vba_stream : #GsfInfile
+ * gsf_infile_msvba_steal_modules:
+ * @vba_stream: #GsfInfile
  *
  * A collection of names and source code which the caller is responsible for destroying.
  *
- * Returns: %NULL, or a hashtable of names and source code (unknown encoding).
+ * Returns: (transfer full): %NULL, or a hashtable of names and source code (unknown encoding).
  **/
 GHashTable *
 gsf_infile_msvba_steal_modules (GsfInfileMSVBA *vba_stream)
@@ -493,13 +493,13 @@ gsf_infile_msvba_steal_modules (GsfInfileMSVBA *vba_stream)
 }
 
 /**
- * gsf_input_find_vba :
- * @input : #GsfInput
- * @err : #GError, optionally %NULL.
+ * gsf_input_find_vba:
+ * @input: #GsfInput
+ * @err: #GError, optionally %NULL.
  *
  * A utility routine that attempts to find the VBA file withint a stream.
  *
- * Returns: a GsfInfileMSVBA *gsf_input_find_vba (GsfInput *input, GError *err);
+ * Returns: (transfer full): a GsfInfileMSVBA *gsf_input_find_vba (GsfInput *input, GError *err);
  **/
 GsfInfileMSVBA *
 gsf_input_find_vba (GsfInput *input, GError **err)
diff --git a/gsf/gsf-infile-stdio.c b/gsf/gsf-infile-stdio.c
index 09379bf..82956aa 100644
--- a/gsf/gsf-infile-stdio.c
+++ b/gsf/gsf-infile-stdio.c
@@ -172,9 +172,9 @@ GSF_CLASS (GsfInfileStdio, gsf_infile_stdio,
 	   GSF_INFILE_TYPE)
 
 /**
- * gsf_infile_stdio_new :
- * @root : in locale dependent encoding
- * @err	 : optionally %NULL.
+ * gsf_infile_stdio_new:
+ * @root: in locale dependent encoding
+ * @err: optionally %NULL.
  *
  * Returns: a new file or %NULL.
  **/
diff --git a/gsf/gsf-infile-tar.c b/gsf/gsf-infile-tar.c
index 2cdb902..0cd76be 100644
--- a/gsf/gsf-infile-tar.c
+++ b/gsf/gsf-infile-tar.c
@@ -554,7 +554,7 @@ GSF_CLASS (GsfInfileTar, gsf_infile_tar,
 	   GSF_INFILE_TYPE)
 
 /**
- * gsf_infile_tar_new :
+ * gsf_infile_tar_new:
  * @source: A base #GsfInput
  * @err: A #GError, optionally %null
  *
diff --git a/gsf/gsf-infile-zip.c b/gsf/gsf-infile-zip.c
index 20cc86b..403d35a 100644
--- a/gsf/gsf-infile-zip.c
+++ b/gsf/gsf-infile-zip.c
@@ -857,7 +857,7 @@ GSF_CLASS (GsfInfileZip, gsf_infile_zip,
 	   GSF_INFILE_TYPE)
 
 /**
- * gsf_infile_zip_new :
+ * gsf_infile_zip_new:
  * @source: A base #GsfInput
  * @err: A #GError, optionally %null
  *
diff --git a/gsf/gsf-infile.c b/gsf/gsf-infile.c
index 52d26ed..99e219f 100644
--- a/gsf/gsf-infile.c
+++ b/gsf/gsf-infile.c
@@ -28,8 +28,8 @@
 #define GET_CLASS(instance) G_TYPE_INSTANCE_GET_CLASS (instance, GSF_INFILE_TYPE, GsfInfileClass)
 
 /**
- * gsf_infile_num_children :
- * @infile : the structured storage
+ * gsf_infile_num_children:
+ * @infile: the structured storage
  *
  * Returns: the number of children the storage has, or -1 if the storage can not
  * 	have children.
@@ -43,9 +43,9 @@ gsf_infile_num_children (GsfInfile *infile)
 }
 
 /**
- * gsf_infile_name_by_index :
- * @infile :
- * @i      :
+ * gsf_infile_name_by_index:
+ * @infile:
+ * @i:
  *
  * Returns: the utf8 encoded name of the @i-th child
  * 	<emphasis>DO NOT FREE THE STRING.</emphasis>
@@ -59,12 +59,12 @@ gsf_infile_name_by_index (GsfInfile *infile, int i)
 }
 
 /**
- * gsf_infile_child_by_index :
- * @infile : #GsfInfile
- * @i : target index
+ * gsf_infile_child_by_index:
+ * @infile: #GsfInfile
+ * @i: target index
  *
  * TODO : For 2.0 api will change to include a GError.
- * Returns: a newly created child which must be unrefed.
+ * Returns: (transfer full): a newly created child which must be unrefed.
  **/
 GsfInput *
 gsf_infile_child_by_index (GsfInfile *infile, int i)
@@ -88,12 +88,12 @@ gsf_infile_child_by_index (GsfInfile *infile, int i)
 }
 
 /**
- * gsf_infile_child_by_name :
- * @infile : #GsfInfile
- * @name : target name
+ * gsf_infile_child_by_name:
+ * @infile: #GsfInfile
+ * @name: target name
  *
  * TODO : For 2.0 api will change to include a GError.
- * Returns: a newly created child which must be unrefed.
+ * Returns: (transfer full): a newly created child which must be unrefed.
  **/
 GsfInput *
 gsf_infile_child_by_name (GsfInfile *infile, char const *name)
@@ -118,11 +118,11 @@ gsf_infile_child_by_name (GsfInfile *infile, char const *name)
 }
 
 /**
- * gsf_infile_child_by_vname :
- * @infile :
- * @Varargs : A %NULL terminated list of names
+ * gsf_infile_child_by_vname:
+ * @infile:
+ * @...: A %NULL terminated list of names
  *
- * Returns: a newly created child which must be unrefed.
+ * Returns: (transfer full): a newly created child which must be unrefed.
  **/
 GsfInput *
 gsf_infile_child_by_vname (GsfInfile *infile,  ...)
@@ -138,13 +138,13 @@ gsf_infile_child_by_vname (GsfInfile *infile,  ...)
 }
 
 /**
- * gsf_infile_child_by_vaname :
- * @infile : #GsfInfile
- * @names : A %NULL terminated array of names (e.g. from g_strsplit)
+ * gsf_infile_child_by_vaname:
+ * @infile: #GsfInfile
+ * @names: A %NULL terminated array of names (e.g. from g_strsplit)
  *
  * New in 1.14.9.
  *
- * Returns: a newly created child which must be unrefed.
+ * Returns: (transfer full): a newly created child which must be unrefed.
  **/
 GsfInput *
 gsf_infile_child_by_vaname (GsfInfile *infile, va_list names)
@@ -171,13 +171,13 @@ gsf_infile_child_by_vaname (GsfInfile *infile, va_list names)
 }
 
 /**
- * gsf_infile_child_by_aname :
- * @infile : #GsfInfile
- * @names : A %NULL terminated array of names (e.g. from g_strsplit)
+ * gsf_infile_child_by_aname:
+ * @infile: #GsfInfile
+ * @names: A %NULL terminated array of names (e.g. from g_strsplit)
  *
  * New in 1.14.9.
  *
- * Returns: a newly created child which must be unrefed.
+ * Returns: (transfer full): a newly created child which must be unrefed.
  **/
 GsfInput *
 gsf_infile_child_by_aname (GsfInfile *infile, char const *names[])
diff --git a/gsf/gsf-input-bzip.c b/gsf/gsf-input-bzip.c
index 55fed78..350e92a 100644
--- a/gsf/gsf-input-bzip.c
+++ b/gsf/gsf-input-bzip.c
@@ -34,9 +34,9 @@
 #endif
 
 /**
- * gsf_input_memory_new_from_bzip :
- * @source : a #GsfInput
- * @err    : a #GError
+ * gsf_input_memory_new_from_bzip:
+ * @source: a #GsfInput
+ * @err: a #GError
  *
  * Returns: a new #GsfInputMemory or %NULL.
  */
diff --git a/gsf/gsf-input-gzip.c b/gsf/gsf-input-gzip.c
index 8ec8e95..0c1bec3 100644
--- a/gsf/gsf-input-gzip.c
+++ b/gsf/gsf-input-gzip.c
@@ -197,9 +197,9 @@ gsf_input_gzip_set_source (GsfInputGZip *gzip, GsfInput *source)
 
 
 /**
- * gsf_input_gzip_new :
- * @source : The underlying data source.
- * @err	   : optionally %NULL.
+ * gsf_input_gzip_new:
+ * @source: The underlying data source.
+ * @err: optionally %NULL.
  *
  * Adds a reference to @source.
  *
diff --git a/gsf/gsf-input-http.c b/gsf/gsf-input-http.c
index 69bfab4..9b78e14 100644
--- a/gsf/gsf-input-http.c
+++ b/gsf/gsf-input-http.c
@@ -186,7 +186,7 @@ gsf_input_http_get_property (GObject *object,
 }
 
 /**
- * gsf_input_http_get_url :
+ * gsf_input_http_get_url:
  * @input: #GsfInputHTTP
  *
  * Returns: an allocated string containing the URL used for input.
@@ -201,7 +201,7 @@ gsf_input_http_get_url (GsfInputHTTP *input)
 }
 
 /**
- * gsf_input_http_get_content_type :
+ * gsf_input_http_get_content_type:
  * @input: #GsfInputHTTP
  *
  * Returns: an allocated string containing the Content-Type field of the HTTP response.
@@ -216,7 +216,7 @@ gsf_input_http_get_content_type (GsfInputHTTP *input)
 }
 
 /**
- * gsf_input_http_new :
+ * gsf_input_http_new:
  * @url: A string containing the URL to retrieve
  * @error: Holds any errors encountered when establishing the HTTP connection
  *
diff --git a/gsf/gsf-input-iochannel.c b/gsf/gsf-input-iochannel.c
index b490345..fd4f00b 100644
--- a/gsf/gsf-input-iochannel.c
+++ b/gsf/gsf-input-iochannel.c
@@ -25,9 +25,9 @@
 #include <gsf-input-memory.h>
 
 /**
- * gsf_input_memory_new_from_iochannel :
- * @channel : a #GIOChannel.
- * @error : a #GError
+ * gsf_input_memory_new_from_iochannel:
+ * @channel: a #GIOChannel.
+ * @error: a #GError
  *
  * Returns: a new #GsfInputMemory or NULL.
  **/
diff --git a/gsf/gsf-input-proxy.c b/gsf/gsf-input-proxy.c
index 4570124..c7f97fb 100644
--- a/gsf/gsf-input-proxy.c
+++ b/gsf/gsf-input-proxy.c
@@ -40,10 +40,10 @@ typedef struct {
 
 
 /**
- * gsf_input_proxy_new_section :
- * @source : The underlying data source.
- * @offset : Offset into source for start of section.
- * @size : Length of section.
+ * gsf_input_proxy_new_section:
+ * @source: The underlying data source.
+ * @offset: Offset into source for start of section.
+ * @size: Length of section.
  *
  * This creates a new proxy to a section of the given source.  The new
  * object will have its own current position, but any operation on it
@@ -90,8 +90,8 @@ gsf_input_proxy_new_section (GsfInput *source,
 }
 
 /**
- * gsf_input_proxy_new :
- * @source : The underlying data source.
+ * gsf_input_proxy_new:
+ * @source: The underlying data source.
  *
  * This creates a new proxy to the entire, given input source.  See
  * gsf_input_proxy_new_section for details.
diff --git a/gsf/gsf-input-stdio.c b/gsf/gsf-input-stdio.c
index b36e98d..fc8f913 100644
--- a/gsf/gsf-input-stdio.c
+++ b/gsf/gsf-input-stdio.c
@@ -105,9 +105,9 @@ error:
 }
 
 /**
- * gsf_input_stdio_new :
- * @filename : in utf8.
- * @err	     : optionally NULL.
+ * gsf_input_stdio_new:
+ * @filename: in utf8.
+ * @err: optionally NULL.
  *
  * Returns: a new file or NULL.
  **/
@@ -162,10 +162,10 @@ gsf_input_stdio_new (char const *filename, GError **err)
 }
 
 /**
- * gsf_input_stdio_new_FILE :
- * @filename  : The filename corresponding to @file.
- * @file      : an existing stdio <type>FILE</type> *
- * @keep_open : Should @file be closed when the wrapper is closed
+ * gsf_input_stdio_new_FILE:
+ * @filename: The filename corresponding to @file.
+ * @file: an existing stdio <type>FILE</type> *
+ * @keep_open: Should @file be closed when the wrapper is closed
  *
  * Assumes ownership of @file when succeeding.  If @keep_open is true,
  * ownership reverts to caller when the GsfObject is closed.
diff --git a/gsf/gsf-input-textline.c b/gsf/gsf-input-textline.c
index 8eddc70..56327ab 100644
--- a/gsf/gsf-input-textline.c
+++ b/gsf/gsf-input-textline.c
@@ -47,8 +47,8 @@ typedef struct {
 } GsfInputTextlineClass;
 
 /**
- * gsf_input_textline_new :
- * @source : in some combination of ascii and utf8
+ * gsf_input_textline_new:
+ * @source: in some combination of ascii and utf8
  *
  * <note>This adds a reference to @source.</note>
  *
@@ -149,8 +149,8 @@ GSF_CLASS (GsfInputTextline, gsf_input_textline,
 	   GSF_INPUT_TYPE)
 
 /**
- * gsf_input_textline_ascii_gets :
- * @textline : #GsfInputTextline
+ * gsf_input_textline_ascii_gets:
+ * @textline: #GsfInputTextline
  *
  * A utility routine to read things line by line from the underlying source.
  * Trailing newlines and carriage returns are stripped, and the resultant buffer
@@ -236,8 +236,8 @@ gsf_input_textline_ascii_gets (GsfInputTextline *textline)
 }
 
 /**
- * gsf_input_textline_utf8_gets :
- * @textline : #GsfInputTextline
+ * gsf_input_textline_utf8_gets:
+ * @textline: #GsfInputTextline
  *
  * A utility routine to read things line by line from the underlying source.
  * Trailing newlines and carriage returns are stripped, and the resultant buffer
diff --git a/gsf/gsf-input.c b/gsf/gsf-input.c
index 1e6cb6c..97d8458 100644
--- a/gsf/gsf-input.c
+++ b/gsf/gsf-input.c
@@ -165,7 +165,7 @@ GSF_CLASS_ABSTRACT (GsfInput, gsf_input,
 		    G_TYPE_OBJECT)
 
 /**
- * gsf_input_name :
+ * gsf_input_name:
  * @input: the input stream
  *
  * The name of the input stream.
@@ -180,10 +180,10 @@ gsf_input_name (GsfInput *input)
 }
 
 /**
- * gsf_input_container :
+ * gsf_input_container:
  * @input: the input stream
  *
- * Returns: but does not add a reference to @input's container.
+ * Returns: (transfer none): but does not add a reference to @input's container.
  * 	Potentially %NULL
  **/
 GsfInfile *
@@ -194,13 +194,13 @@ gsf_input_container (GsfInput *input)
 }
 
 /**
- * gsf_input_dup :
+ * gsf_input_dup:
  * @input: The input to duplicate
  * @err: optionally %NULL
  *
  * Duplicates input @src leaving the new one at the same offset.
  *
- * Returns: the duplicate, or %NULL on error
+ * Returns: (transfer full): the duplicate, or %NULL on error
  **/
 GsfInput *
 gsf_input_dup (GsfInput *input, GError **err)
@@ -235,8 +235,10 @@ gsf_input_dup (GsfInput *input, GError **err)
 }
 
 /**
- * gsf_input_open_sibling :
+ * gsf_input_sibling:
  * @input: The input
+ * @name: name.
+ * @err: #GError
  *
  * UNIMPLEMENTED BY ANY BACKEND
  * 	and it is probably unnecessary.   gsf_input_get_container provides
@@ -245,7 +247,7 @@ gsf_input_dup (GsfInput *input, GError **err)
  * Attempts to open a 'sibling' of @input.  The caller is responsible for
  * managing the resulting object.
  *
- * Returns:  A related #GsfInput or %NULL on failure.
+ * Returns: (transfer full): A related #GsfInput or %NULL on failure.
  **/
 GsfInput *
 gsf_input_sibling (GsfInput const *input, char const *name, GError **err)
@@ -256,7 +258,7 @@ gsf_input_sibling (GsfInput const *input, char const *name, GError **err)
 }
 
 /**
- * gsf_input_size :
+ * gsf_input_size:
  * @input: The input
  *
  * Looks up and caches the number of bytes in the input
@@ -271,7 +273,7 @@ gsf_input_size (GsfInput *input)
 }
 
 /**
- * gsf_input_eof :
+ * gsf_input_eof:
  * @input: the input
  *
  * Are we at the end of the file ?
@@ -287,7 +289,7 @@ gsf_input_eof (GsfInput *input)
 }
 
 /**
- * gsf_input_read :
+ * gsf_input_read:
  * @input: the input stream
  * @num_bytes: number of bytes to read
  * @optional_buffer: %NULL, or pointer to destination memory area
@@ -318,7 +320,7 @@ gsf_input_read (GsfInput *input, size_t num_bytes, guint8 *optional_buffer)
 }
 
 /**
- * gsf_input_remaining :
+ * gsf_input_remaining:
  * @input: the input stream
  *
  * Returns: the number of bytes left in the file.
@@ -332,7 +334,7 @@ gsf_input_remaining (GsfInput *input)
 }
 
 /**
- * gsf_input_tell :
+ * gsf_input_tell:
  * @input: the input stream
  *
  * Returns: the current offset in the file.
@@ -346,7 +348,7 @@ gsf_input_tell (GsfInput *input)
 }
 
 /**
- * gsf_input_seek :
+ * gsf_input_seek:
  * @input: the input stream
  * @offset: target offset
  * @whence: determines whether the offset is relative to the beginning or
@@ -388,7 +390,7 @@ gsf_input_seek (GsfInput *input, gsf_off_t offset, GSeekType whence)
 }
 
 /**
- * gsf_input_set_name :
+ * gsf_input_set_name:
  * @input: the input stream
  * @name: the new name of the stream, or %NULL.
  *
@@ -411,7 +413,7 @@ gsf_input_set_name (GsfInput *input, char const *name)
 }
 
 /**
- * gsf_input_set_name_from_filename :
+ * gsf_input_set_name_from_filename:
  * @input: the input stream
  * @filename: the (fs-sys encoded) filename
  *
@@ -431,7 +433,7 @@ gsf_input_set_name_from_filename (GsfInput *input, char const *filename)
 
 
 /**
- * gsf_input_set_container :
+ * gsf_input_set_container:
  * @input: the input stream
  * @container:
  *
@@ -451,7 +453,7 @@ gsf_input_set_container (GsfInput *input, GsfInfile *container)
 }
 
 /**
- * gsf_input_set_size :
+ * gsf_input_set_size:
  * @input: the input stream
  * @size: the size of the stream
  *
@@ -468,7 +470,7 @@ gsf_input_set_size (GsfInput *input, gsf_off_t size)
 }
 
 /**
- * gsf_input_seek_emulate :
+ * gsf_input_seek_emulate:
  * @input: stream to emulate seek for
  * @pos: absolute position to seek to
  *
@@ -493,7 +495,7 @@ gsf_input_seek_emulate (GsfInput *input, gsf_off_t pos)
 /****************************************************************************/
 
 /**
- * gsf_input_error_id :
+ * gsf_input_error_id:
  *
  * Returns: A utility quark to flag a GError as being an input problem.
  */
@@ -507,7 +509,7 @@ gsf_input_error_id (void)
 }
 
 /**
- * gsf_input_error :
+ * gsf_input_error:
  *
  * Deprecated as of GSF 1.12.0; use gsf_input_error_id() instead.
  *
@@ -524,7 +526,7 @@ gsf_input_error (void)
 #define GSF_READ_BUFSIZE (1024 * 4)
 
 /**
- * gsf_input_copy :
+ * gsf_input_copy:
  * @input: a non-null #GsfInput
  * @output: a non-null #GsfOutput
  *
@@ -560,13 +562,13 @@ gsf_input_copy (GsfInput *input, GsfOutput *output)
 /****************************************************************************/
 
 /**
- * gsf_input_uncompress :
- * @src: stream to be uncompressed.
+ * gsf_input_uncompress:
+ * @src: (transfer full): stream to be uncompressed.
  *
  * This functions takes ownership of the incoming reference and yields a
  * new one as its output.
  *
- * Returns: A stream equivalent to the source stream, but uncompressed if
+ * Returns: (transfer full): A stream equivalent to the source stream, but uncompressed if
  * the source was compressed.
  **/
 GsfInput *
diff --git a/gsf/gsf-libxml.c b/gsf/gsf-libxml.c
index 31bf805..fa37d42 100644
--- a/gsf/gsf-libxml.c
+++ b/gsf/gsf-libxml.c
@@ -188,10 +188,10 @@ glade_string_from_flags (GType type, guint flags)
 }
 
 /**
- * gsf_xml_gvalue_from_str :
- * @res : Result value
- * @t : Type of data
- * @str : Value string
+ * gsf_xml_gvalue_from_str:
+ * @res: Result value
+ * @t: Type of data
+ * @str: Value string
  *
  * Try to parse @str as a value of type @t into @res.
  *
@@ -333,8 +333,8 @@ gsf_xml_parser_context_full (GsfInput *input, xmlSAXHandlerPtr sax, gpointer use
 }
 
 /**
- * gsf_xml_parser_context :
- * @input : #GsfInput
+ * gsf_xml_parser_context: (skip)
+ * @input: #GsfInput
  *
  * Create a libxml2 pull style parser context wrapper around gsf input @input.
  * This signature will probably change to supply a SAX structure.
@@ -343,6 +343,8 @@ gsf_xml_parser_context_full (GsfInput *input, xmlSAXHandlerPtr sax, gpointer use
  * <note>A simple wrapper around a cleaner implementation that will fold in
  * when we add other api changes.  Its not worth bumping just for this.</note>
  *
+ * NOTE: skipped since xmlParserCtxt is not exported to introspection.
+ *
  * Returns: A parser context or %NULL
  **/
 xmlParserCtxtPtr
@@ -352,7 +354,7 @@ gsf_xml_parser_context (GsfInput *input)
 }
 
 /**
- * gsf_xml_output_buffer_new :
+ * gsf_xml_output_buffer_new:
  * @output: #GsfOutput
  * @encoding: optionally %NULL.
  *
@@ -375,11 +377,11 @@ gsf_xml_output_buffer_new (GsfOutput *output,
 }
 
 /**
- * gsf_xmlDocFormatDump :
- * @output : #GsfOutput
- * @cur : #xmlDocPtr
- * @encoding : The encoding to use.
- * @format : %TRUE to reformat the output.
+ * gsf_xmlDocFormatDump:
+ * @output: #GsfOutput
+ * @cur: #xmlDocPtr
+ * @encoding: The encoding to use.
+ * @format: %TRUE to reformat the output.
  *
  * Dumps the document @cur into @output.
  *
@@ -456,6 +458,13 @@ gsf_xml_probe_element (GsfXMLProbeState *state,
 	state->func = NULL;
 }
 
+/**
+ * gsf_xml_probe:
+ * @input: #GsfInput
+ * @func: (scope call): #GsfXMLProbeFunc
+ *
+ * Returns: TRUE on success.
+ */
 gboolean
 gsf_xml_probe (GsfInput *input, GsfXMLProbeFunc func)
 {
@@ -533,6 +542,7 @@ struct _GsfXMLInDoc {
 	GHashTable      *symbols; /* GsfXMLInNodeInternal hashed by id */
 	GsfXMLInNS const*ns;
 	GsfXMLInUnknownFunc	unknown_handler;
+	unsigned ref_count;
 };
 typedef struct {
 	GsfXMLIn	pub;
@@ -1012,29 +1022,32 @@ gsf_xml_in_node_internal_free (GsfXMLInNodeInternal *node)
 }
 
 /**
- * gsf_xml_in_doc_free :
- * @doc : #GsfXMLInDoc
+ * gsf_xml_in_doc_free:
+ * @doc: #GsfXMLInDoc
  *
  * Free up resources
  **/
 void
 gsf_xml_in_doc_free (GsfXMLInDoc *doc)
 {
-	g_return_if_fail (doc != NULL);
-	g_return_if_fail (doc->symbols != NULL);
+	doc->ref_count--;
+	if (doc->ref_count == 0) {
+		g_return_if_fail (doc != NULL);
+		g_return_if_fail (doc->symbols != NULL);
 
-	g_hash_table_destroy (doc->symbols);
+		g_hash_table_destroy (doc->symbols);
 
-	/* poison the well just in case */
-	doc->symbols   = NULL;
-	doc->root_node = NULL;
-	g_free (doc);
+		/* poison the well just in case */
+		doc->symbols   = NULL;
+		doc->root_node = NULL;
+		g_free (doc);
+	}
 }
 
 /**
- * gsf_xml_in_doc_new :
- * @nodes : an array of node descriptors
- * @ns : an array of namespace identifiers
+ * gsf_xml_in_doc_new:
+ * @nodes: an array of node descriptors
+ * @ns: an array of namespace identifiers
  *
  * Combine the nodes in the %NULL terminated array starting at @nodes with the
  * name spaces in the %NULL terminated array starting at @ns.  Prepare the
@@ -1061,14 +1074,35 @@ gsf_xml_in_doc_new (GsfXMLInNode const *nodes, GsfXMLInNS const *ns)
 		gsf_xml_in_doc_free (doc);
 		g_return_val_if_fail (NULL != doc->root_node, NULL);
 	}
+	doc->ref_count = 1;
+
+	return doc;
+}
 
+static GsfXMLInDoc *
+gsf_xml_in_doc_ref (GsfXMLInDoc *doc) {
+	doc->ref_count++;
 	return doc;
 }
 
+GType
+gsf_xml_in_doc_get_type (void)
+{
+    static GType type = 0;
+
+    if (type == 0)
+	type = g_boxed_type_register_static
+	    ("GsfXMLInDoc",
+	     (GBoxedCopyFunc) gsf_xml_in_doc_ref,
+	     (GBoxedFreeFunc) gsf_xml_in_doc_free);
+
+    return type;
+}
+
 /**
- * gsf_xml_in_doc_add_nodes :
- * @doc : #GsfXMLInDoc
- * @nodes : %NULL terminated array of #GsfXMLInNode
+ * gsf_xml_in_doc_add_nodes:
+ * @doc: #GsfXMLInDoc
+ * @nodes: %NULL terminated array of #GsfXMLInNode
  *
  * Adds additional nodes to the structure of @doc
  **/
@@ -1138,8 +1172,8 @@ gsf_xml_in_doc_add_nodes (GsfXMLInDoc *doc,
 
 /**
  * gsf_xml_in_doc_set_unknown_handler:
- * @doc : #GsfXMLInDoc
- * @handler : The function to call
+ * @doc: #GsfXMLInDoc
+ * @handler: (scope call): The function to call
  *
  * Call the function @handler when an unexpected child node is found
  **/
@@ -1152,12 +1186,12 @@ gsf_xml_in_doc_set_unknown_handler (GsfXMLInDoc *doc,
 }
 
 /**
- * gsf_xml_in_push_state :
- * @xin : #GsfXMLIn
- * @doc : #GsfXMLInDoc
- * @new_state : arbitrary content for the parser
- * @dtor : #GsfXMLInExtDtor
- * @attrs : array of xmlChar const *
+ * gsf_xml_in_push_state:
+ * @xin: #GsfXMLIn
+ * @doc: #GsfXMLInDoc
+ * @new_state: arbitrary content for the parser
+ * @dtor: (scope call): #GsfXMLInExtDtor
+ * @attrs: array of xmlChar const *
  *
  * Take the first node from @doc as the current node and call its start handler.
  **/
@@ -1185,10 +1219,10 @@ gsf_xml_in_push_state (GsfXMLIn *xin, GsfXMLInDoc const *doc,
 }
 
 /**
- * gsf_xml_in_doc_parse :
- * @doc : #GsfXMLInDoc
- * @input : #GsfInput
- * @user_state : arbitrary content stored in the parser
+ * gsf_xml_in_doc_parse:
+ * @doc: #GsfXMLInDoc
+ * @input: #GsfInput
+ * @user_state: arbitrary content stored in the parser
  *
  * Read an xml document from @input and parse based on the the descriptor in
  * @doc
@@ -1220,13 +1254,35 @@ gsf_xml_in_doc_parse (GsfXMLInDoc *doc, GsfInput *input, gpointer user_state)
 	return res;
 }
 
+static GsfXMLInNS *
+gsf_xml_in_ns_copy (GsfXMLInNS *ns) {
+	GsfXMLInNS *res = g_new (GsfXMLInNS, 1);
+	res->uri = ns->uri;
+	res->ns_id = ns->ns_id;
+	return res;
+}
+
+GType
+gsf_xml_in_ns_get_type (void)
+{
+    static GType type = 0;
+
+    if (type == 0)
+	type = g_boxed_type_register_static
+	    ("GsfXMLInNS",
+	     (GBoxedCopyFunc) gsf_xml_in_ns_copy,
+	     (GBoxedFreeFunc) g_free);
+
+    return type;
+}
+
 /**
- * gsf_xml_in_get_input :
- * @xin : #GsfXMLIn
+ * gsf_xml_in_get_input:
+ * @xin: #GsfXMLIn
  *
  * (New in 1.14.2)
  *
- * Returns: (but does not reference) the stream being parsed.
+ * Returns: (transfer none): (but does not reference) the stream being parsed.
  **/
 GsfInput *
 gsf_xml_in_get_input (GsfXMLIn const *xin)
@@ -1236,10 +1292,10 @@ gsf_xml_in_get_input (GsfXMLIn const *xin)
 }
 
 /**
- * gsf_xml_in_check_ns :
- * @xin : #GsfXMLIn
- * @str : string to check
- * @ns_id : the namespace id
+ * gsf_xml_in_check_ns:
+ * @xin: #GsfXMLIn
+ * @str: string to check
+ * @ns_id: the namespace id
  *
  * According to @state is @str in the namespace @ns_id ?
  *
@@ -1267,11 +1323,11 @@ gsf_xml_in_check_ns (GsfXMLIn const *xin, char const *str, unsigned int ns_id)
 }
 
 /**
- * gsf_xml_in_namecmp :
- * @xin   : The #GsfXMLIn we are reading from.
- * @str   : The potentially namespace qualified node name.
- * @ns_id : The name space id to check
- * @name  : The target node name
+ * gsf_xml_in_namecmp:
+ * @xin: The #GsfXMLIn we are reading from.
+ * @str: The potentially namespace qualified node name.
+ * @ns_id: The name space id to check
+ * @name: The target node name
  *
  * Checks to see if @str is the same as @ns_id::@name with either an explicit
  * namespace or the current default namespace.
@@ -1430,8 +1486,8 @@ GSF_CLASS (GsfXMLOut, gsf_xml_out,
 	   G_TYPE_OBJECT)
 
 /**
- * gsf_xml_out_new :
- * @output : #GsfOutput
+ * gsf_xml_out_new:
+ * @output: #GsfOutput
  *
  * Create an XML output stream.
  *
@@ -1448,9 +1504,9 @@ gsf_xml_out_new (GsfOutput *output)
 }
 
 /**
- * gsf_xml_out_set_doc_type :
- * @xout : #GsfXMLOut
- * @type : the document type declaration
+ * gsf_xml_out_set_doc_type:
+ * @xout: #GsfXMLOut
+ * @type: the document type declaration
  *
  * Store some optional some &lt;!DOCTYPE .. &gt; content
  **/
@@ -1482,9 +1538,9 @@ gsf_xml_out_indent (GsfXMLOut *xout)
 }
 
 /**
- * gsf_xml_out_start_element :
- * @xout : #GsfXMLOut
- * @id  : Element name
+ * gsf_xml_out_start_element:
+ * @xout: #GsfXMLOut
+ * @id: Element name
  *
  * Output a start element @id, if necessary preceeded by an XML declaration.
  */
@@ -1521,8 +1577,8 @@ gsf_xml_out_start_element (GsfXMLOut *xout, char const *id)
 }
 
 /**
- * gsf_xml_out_end_element :
- * @xout : #GsfXMLOut
+ * gsf_xml_out_end_element:
+ * @xout: #GsfXMLOut
  *
  * Closes/ends an XML element.
  *
@@ -1563,10 +1619,10 @@ gsf_xml_out_end_element (GsfXMLOut *xout)
 }
 
 /**
- * gsf_xml_out_simple_element :
- * @xout : #GsfXMLOut
- * @id  : Element name
- * @content : Content of the element
+ * gsf_xml_out_simple_element:
+ * @xout: #GsfXMLOut
+ * @id: Element name
+ * @content: Content of the element
  *
  * Convenience routine to output a simple @id element with content @content.
  **/
@@ -1581,10 +1637,10 @@ gsf_xml_out_simple_element (GsfXMLOut *xout, char const *id,
 }
 
 /**
- * gsf_xml_out_simple_int_element :
- * @xout : #GsfXMLOut
- * @id  : Element name
- * @val : Element value
+ * gsf_xml_out_simple_int_element:
+ * @xout: #GsfXMLOut
+ * @id: Element name
+ * @val: Element value
  *
  * Convenience routine to output an element @id with integer value @val.
  **/
@@ -1597,11 +1653,11 @@ gsf_xml_out_simple_int_element (GsfXMLOut *xout, char const *id, int val)
 }
 
 /**
- * gsf_xml_out_simple_float_element :
- * @xout : #GsfXMLOut
- * @id  : Element name
- * @val : Element value
- * @precision : the number of significant digits to use, -1 meaning "enough".
+ * gsf_xml_out_simple_float_element:
+ * @xout: #GsfXMLOut
+ * @id: Element name
+ * @val: Element value
+ * @precision: the number of significant digits to use, -1 meaning "enough".
  *
  * Convenience routine to output an element @id with float value @val using
  * @precision significant digits.
@@ -1626,10 +1682,10 @@ close_tag_if_neccessary (GsfXMLOut* xout)
 }
 
 /**
- * gsf_xml_out_add_cstr_unchecked :
- * @xout : #GsfXMLOut
- * @id : optionally NULL for content
- * @val_utf8 : a utf8 encoded string to export
+ * gsf_xml_out_add_cstr_unchecked:
+ * @xout: #GsfXMLOut
+ * @id: optionally NULL for content
+ * @val_utf8: a utf8 encoded string to export
  *
  * dump @val_utf8 to an attribute named @id without checking to see if the
  * content needs escaping.  A useful performance enhancement when the
@@ -1653,10 +1709,10 @@ gsf_xml_out_add_cstr_unchecked (GsfXMLOut *xout, char const *id,
 }
 
 /**
- * gsf_xml_out_add_cstr :
- * @xout : #GsfXMLOut
- * @id : optionally NULL for content
- * @val_utf8 : a utf8 encoded string
+ * gsf_xml_out_add_cstr:
+ * @xout: #GsfXMLOut
+ * @id: optionally NULL for content
+ * @val_utf8: a utf8 encoded string
  *
  * dump @val_utf8 to an attribute named @id or as the nodes content escaping
  * characters as necessary.  If @val_utf8 is NULL do nothing (no warning, no
@@ -1732,10 +1788,10 @@ gsf_xml_out_add_cstr (GsfXMLOut *xout, char const *id,
 }
 
 /**
- * gsf_xml_out_add_bool :
- * @xout : #GsfXMLOut
- * @id  : optionally NULL for content
- * @val : a boolean
+ * gsf_xml_out_add_bool:
+ * @xout: #GsfXMLOut
+ * @id: optionally NULL for content
+ * @val: a boolean
  *
  * dump boolean value @val to an attribute named @id or as the nodes content
  * Use '1' or '0' to simplify import
@@ -1749,10 +1805,10 @@ gsf_xml_out_add_bool (GsfXMLOut *xout, char const *id,
 }
 
 /**
- * gsf_xml_out_add_int :
- * @xout : #GsfXMLOut
- * @id  : optionally NULL for content
- * @val : the value
+ * gsf_xml_out_add_int:
+ * @xout: #GsfXMLOut
+ * @id: optionally NULL for content
+ * @val: the value
  *
  * dump integer value @val to an attribute named @id or as the nodes content
  **/
@@ -1766,10 +1822,10 @@ gsf_xml_out_add_int (GsfXMLOut *xout, char const *id,
 }
 
 /**
- * gsf_xml_out_add_uint :
- * @xout : #GsfXMLOut
- * @id  : optionally NULL for content
- * @val : the value
+ * gsf_xml_out_add_uint:
+ * @xout: #GsfXMLOut
+ * @id: optionally NULL for content
+ * @val: the value
  *
  * dump unsigned integer value @val to an attribute named @id or as the nodes
  * content
@@ -1784,11 +1840,11 @@ gsf_xml_out_add_uint (GsfXMLOut *xout, char const *id,
 }
 
 /**
- * gsf_xml_out_add_float :
- * @xout : #GsfXMLOut
- * @id  : optionally NULL for content
- * @val : the value
- * @precision : the number of significant digits to use, -1 meaning "enough".
+ * gsf_xml_out_add_float:
+ * @xout: #GsfXMLOut
+ * @id: optionally NULL for content
+ * @val: the value
+ * @precision: the number of significant digits to use, -1 meaning "enough".
  *
  * dump float value @val to an attribute named @id or as the nodes
  * content with precision @precision.  The number will be formattted
@@ -1810,12 +1866,12 @@ gsf_xml_out_add_float (GsfXMLOut *xout, char const *id,
 }
 
 /**
- * gsf_xml_out_add_color :
- * @xout : #GsfXMLOut
- * @id  : optionally NULL for content
- * @r : Red value
- * @g : Green value
- * @b : Blue value
+ * gsf_xml_out_add_color:
+ * @xout: #GsfXMLOut
+ * @id: optionally NULL for content
+ * @r: Red value
+ * @g: Green value
+ * @b: Blue value
  *
  * dump Color @r  g @b to an attribute named @id or as the nodes content
  **/
@@ -1829,11 +1885,11 @@ gsf_xml_out_add_color (GsfXMLOut *xout, char const *id,
 }
 
 /**
- * gsf_xml_out_add_enum :
- * @xout : #GsfXMLOut
- * @id  : optionally NULL for content
- * @etype : #GType
- * @val : enum element number
+ * gsf_xml_out_add_enum:
+ * @xout: #GsfXMLOut
+ * @id: optionally NULL for content
+ * @etype: #GType
+ * @val: enum element number
  *
  * Output the name of value @val of enumeration type @etype.
  **/
@@ -1852,10 +1908,10 @@ gsf_xml_out_add_enum (GsfXMLOut *xout, char const *id, GType etype, gint val)
 }
 
 /**
- * gsf_xml_out_add_gvalue :
- * @xout : #GsfXMLOut
- * @id  : optionally NULL for content
- * @val : #GValue
+ * gsf_xml_out_add_gvalue:
+ * @xout: #GsfXMLOut
+ * @id: optionally NULL for content
+ * @val: #GValue
  *
  * Output the value of @val as a string.  Does NOT store any type information
  * with the string, just thevalue.
@@ -1933,11 +1989,11 @@ gsf_xml_out_add_gvalue (GsfXMLOut *xout, char const *id, GValue const *val)
 }
 
 /**
- * gsf_xml_out_add_base64 :
- * @xout : #GsfXMLOut
- * @id  : optionally NULL for content
- * @data : Data to be written
- * @len : Length of data
+ * gsf_xml_out_add_base64:
+ * @xout: #GsfXMLOut
+ * @id: optionally NULL for content
+ * @data: Data to be written
+ * @len: Length of data
  *
  * dump @len bytes in @data into the content of node @id using base64
  **/
@@ -1958,12 +2014,12 @@ gsf_xml_out_add_base64 (GsfXMLOut *xout, char const *id,
 }
 
 /**
- * gsf_xml_out_get_output :
- * @xout : #GsfXMLOut
+ * gsf_xml_out_get_output:
+ * @xout: #GsfXMLOut
  *
  * Get the #GsfInput we are parsing from.
  *
- * Returns: #GsfInput or %NULL.
+ * Returns: (transfer none): #GsfInput or %NULL.
  **/
 GsfOutput *
 gsf_xml_out_get_output (GsfXMLOut const *xout)
diff --git a/gsf/gsf-libxml.h b/gsf/gsf-libxml.h
index a8e1f0a..e9ab640 100644
--- a/gsf/gsf-libxml.h
+++ b/gsf/gsf-libxml.h
@@ -49,7 +49,7 @@ typedef gboolean (*GsfXMLProbeFunc) (const xmlChar *name,
 				     int nb_defaulted,
 				     const xmlChar **attributes);
 gboolean gsf_xml_probe (GsfInput *input,
-			GsfXMLProbeFunc startElement);
+			GsfXMLProbeFunc func);
 
 /****************************************************************************/
 /* Simplified wrapper to SAX based xml import */
@@ -130,6 +130,7 @@ struct _GsfXMLInNS {
 #define GSF_XML_IN_NODE_END	\
 	{ NULL, 0, NULL, NULL, NULL, NULL, { 0 }, GSF_XML_NO_CONTENT, FALSE, FALSE }
 
+GType	     gsf_xml_in_doc_get_type (void);
 GsfXMLInDoc *gsf_xml_in_doc_new	   (GsfXMLInNode const *nodes, GsfXMLInNS const *ns);
 void	     gsf_xml_in_doc_free   (GsfXMLInDoc *doc);
 gboolean     gsf_xml_in_doc_parse  (GsfXMLInDoc *doc, GsfInput *input,
@@ -149,9 +150,13 @@ char const  *gsf_xml_in_check_ns   (GsfXMLIn const *xin, char const *str,
 gboolean     gsf_xml_in_namecmp	   (GsfXMLIn const *xin, char const *str,
 				    unsigned int ns_id, char const *name);
 
+GType	     gsf_xml_in_ns_get_type (void);
+
 /****************************************************************************/
 /* Simplified GSF based xml export (does not use libxml) */
 
+typedef struct _GsfXMLOut		GsfXMLOut;
+
 typedef struct {
 	GObjectClass  base;
 
@@ -163,13 +168,13 @@ typedef struct {
 	void (*_gsf_reserved4) (void);
 } GsfXMLOutClass;
 
-typedef struct _GsfXMLOut {
+struct _GsfXMLOut {
 	GObject	   base;
 	GsfOutput *output;
 
 	/*< private >*/
 	struct _GsfXMLOutPrivate *priv;
-} GsfXMLOut;
+};
 
 #define GSF_XML_OUT_TYPE	(gsf_xml_out_get_type ())
 #define GSF_XML_OUT(o)		(G_TYPE_CHECK_INSTANCE_CAST ((o), GSF_XML_OUT_TYPE, GsfXMLOut))
diff --git a/gsf/gsf-msole-utils.c b/gsf/gsf-msole-utils.c
index 07f1e0c..a2201dc 100644
--- a/gsf/gsf-msole-utils.c
+++ b/gsf/gsf-msole-utils.c
@@ -1087,9 +1087,9 @@ msole_prop_cmp (gconstpointer a, gconstpointer b)
 }
 
 /**
- * gsf_msole_metadata_read :
- * @in    : #GsfInput
- * @accum : #GsfDocMetaData
+ * gsf_msole_metadata_read:
+ * @in: #GsfInput
+ * @accum: #GsfDocMetaData
  *
  * Read a stream formated as a set of MS OLE properties from @in and store the
  * results in @accum.
@@ -1614,10 +1614,10 @@ cb_count_props (char const *name, GsfDocProp *prop, WritePropState *state)
 }
 
 /**
- * gsf_msole_metadata_write :
- * @out : #GsfOutput
- * @meta_data : #GsfDocMetaData
- * @doc_not_component : a kludge to differentiate DocumentSummary from Summary
+ * gsf_msole_metadata_write:
+ * @out: #GsfOutput
+ * @meta_data: #GsfDocMetaData
+ * @doc_not_component: a kludge to differentiate DocumentSummary from Summary
  *
  * Returns: %TRUE on success;
  **/
@@ -1877,8 +1877,8 @@ static struct {
 };
 
 /**
- * gsf_msole_lid_for_language
- * @lang :
+ * gsf_msole_lid_for_language:
+ * @lang:
  *
  * Returns: the LID (Language Identifier) for the input language.
  * 	If lang is %null, return 0x0400 ("-none-"), and not 0x0000 ("no proofing")
@@ -1902,8 +1902,8 @@ gsf_msole_lid_for_language (char const *lang)
 }
 
 /**
- * gsf_msole_language_for_lid :
- * @lid :
+ * gsf_msole_language_for_lid:
+ * @lid:
  *
  * Returns: the xx_YY style string (can be just xx or xxx) for the given LID.
  * 	Return value must not be freed. If the LID is not found, is set to
@@ -1922,9 +1922,9 @@ gsf_msole_language_for_lid (guint lid)
 }
 
 /**
- * gsf_msole_locale_to_lid :
+ * gsf_msole_locale_to_lid:
  *
- * Covert the the codepage into an applicable LID
+ * Convert the the codepage into an applicable LID
  **/
 guint
 gsf_msole_codepage_to_lid (int codepage)
@@ -1967,8 +1967,8 @@ gsf_msole_codepage_to_lid (int codepage)
 }
 
 /**
- * gsf_msole_lid_to_codepage
- * @lid :
+ * gsf_msole_lid_to_codepage:
+ * @lid:
  *
  * Returns: our best guess at the codepage for the given language id
  **/
@@ -2168,8 +2168,8 @@ gsf_msole_lid_to_codepage (guint lid)
 }
 
 /**
- * gsf_msole_lid_to_codepage_str
- * @lid :
+ * gsf_msole_lid_to_codepage_str:
+ * @lid:
  *
  * Returns: the Iconv codepage string for the given LID.
  * 	Return value must be g_free ()'d
@@ -2187,7 +2187,7 @@ gsf_msole_lid_to_codepage_str (guint lid)
 }
 
 /**
- * gsf_msole_iconv_win_codepage :
+ * gsf_msole_iconv_win_codepage:
  *
  * Returns: our best guess at the applicable windows code page based on an
  * 	environment variable or the current locale.
@@ -2250,9 +2250,11 @@ gsf_msole_iconv_get_codepage_string_list (int codepage)
 }
 
 /**
- * gsf_msole_iconv_open_codepage_for_import :
- * @to:
- * @codepage :
+ * gsf_msole_iconv_open_codepage_for_import: (skip)
+ * @to: the target encoding.
+ * @codepage: the source code page.
+ *
+ * NOTE: skipped since GIConv is not exported to introspection.
  *
  * Returns: an iconv converter for @codepage -> utf8.
  **/
@@ -2281,8 +2283,10 @@ gsf_msole_iconv_open_codepage_for_import (char const *to, int codepage)
 }
 
 /**
- * gsf_msole_iconv_open_for_import :
- * @codepage :
+ * gsf_msole_iconv_open_for_import: (skip)
+ * @codepage: the source code page.
+ *
+ * NOTE: skipped since GIConv is not exported to introspection.
  *
  * Returns: an iconv converter for single byte encodings @codepage -> utf8.
  * 	Attempt to handle the semantics of a specification for multibyte encodings
@@ -2295,9 +2299,11 @@ gsf_msole_iconv_open_for_import (int codepage)
 }
 
 /**
- * gsf_msole_iconv_open_codepages_for_export :
- * @codepage_to :
- * @from :
+ * gsf_msole_iconv_open_codepages_for_export: (skip)
+ * @codepage_to: the target code page.
+ * @from: the source encoding.
+ *
+ * NOTE: skipped since GIConv is not exported to introspection.
  *
  * Returns: an iconv converter to go from utf8 -> to our best guess at a useful
  * 	windows codepage.
@@ -2327,8 +2333,10 @@ gsf_msole_iconv_open_codepages_for_export (int codepage_to, char const *from)
 }
 
 /**
- * gsf_msole_iconv_open_codepage_for_export :
- * @codepage_to:
+ * gsf_msole_iconv_open_codepage_for_export: (skip)
+ * @codepage_to: the target code page.
+ *
+ * NOTE: skipped since GIConv is not exported to introspection.
  *
  * Returns: an iconv converter to go from utf8 -> to our best guess at a useful
  * 	windows codepage.
@@ -2340,7 +2348,9 @@ gsf_msole_iconv_open_codepage_for_export (int codepage_to)
 }
 
 /**
- * gsf_msole_iconv_open_for_export :
+ * gsf_msole_iconv_open_for_export: (skip)
+ *
+ * NOTE: skipped since GIConv is not exported to introspection.
  *
  * Returns: an iconv convert to go from utf8 -> to our best guess at a useful
  * 	windows codepage.
@@ -2360,7 +2370,7 @@ gsf_msole_iconv_open_for_export (void)
  *
  * Decompresses an LZ compressed stream.
  *
- * Return value: A GByteArray that the caller is responsible for freeing
+ * Return value: (transfer full): A GByteArray that the caller is responsible for freeing
  **/
 GByteArray *
 gsf_msole_inflate (GsfInput *input, gsf_off_t offset)
@@ -2485,6 +2495,30 @@ gsf_msole_sorting_key_free (GsfMSOleSortingKey *sk)
 	}
 }
 
+static GsfMSOleSortingKey *
+gsf_ms_ole_sorting_key_copy (GsfMSOleSortingKey *sk)
+{
+	GsfMSOleSortingKey *res = g_new (GsfMSOleSortingKey, 1);
+	res->len = sk->len;
+	res->name = g_new (gunichar2, sk->len + 1);
+	memcpy (res->name, sk->name, (sk->len + 1) * sizeof (gunichar2));
+	return res;
+}
+
+GType
+gsf_msole_sorting_key_get_type (void)
+{
+    static GType type = 0;
+
+    if (type == 0)
+	type = g_boxed_type_register_static
+	    ("GsfMSOleSortingKey",
+	     (GBoxedCopyFunc) gsf_ms_ole_sorting_key_copy,
+	     (GBoxedFreeFunc) gsf_msole_sorting_key_free);
+
+    return type;
+}
+
 int
 gsf_msole_sorting_key_cmp (const GsfMSOleSortingKey *a,
 			   const GsfMSOleSortingKey *b)
diff --git a/gsf/gsf-msole-utils.h b/gsf/gsf-msole-utils.h
index 8a9a8ea..9052479 100644
--- a/gsf/gsf-msole-utils.h
+++ b/gsf/gsf-msole-utils.h
@@ -50,6 +50,7 @@ GIConv	    gsf_msole_iconv_open_codepage_for_export  (int codepage_to);
 GByteArray *gsf_msole_inflate (GsfInput *input, gsf_off_t offset);
 
 typedef struct GsfMSOleSortingKey_ GsfMSOleSortingKey;
+GType gsf_msole_sorting_key_get_type (void);
 GsfMSOleSortingKey *gsf_msole_sorting_key_new (const char *name);
 void gsf_msole_sorting_key_free (GsfMSOleSortingKey *sk);
 int gsf_msole_sorting_key_cmp (const GsfMSOleSortingKey *a,
diff --git a/gsf/gsf-open-pkg-utils.c b/gsf/gsf-open-pkg-utils.c
index 56fa61e..ed133bb 100644
--- a/gsf/gsf-open-pkg-utils.c
+++ b/gsf/gsf-open-pkg-utils.c
@@ -112,8 +112,8 @@ GSF_XML_IN_NODE_END
 };
 
 /**
- * gsf_open_pkg_rel_is_extern :
- * @rel : #GsfOpenPkgRel
+ * gsf_open_pkg_rel_is_extern:
+ * @rel: #GsfOpenPkgRel
  *
  * Returns: %TRUE if @rel has mode 'External'
  **/
@@ -125,8 +125,8 @@ gsf_open_pkg_rel_is_extern (GsfOpenPkgRel const *rel)
 }
 
 /**
- * gsf_open_pkg_rel_get_target :
- * @rel : #GsfOpenPkgRel
+ * gsf_open_pkg_rel_get_target:
+ * @rel: #GsfOpenPkgRel
  *
  * Returns: const pointer to @rel's target.
  **/
@@ -138,9 +138,9 @@ gsf_open_pkg_rel_get_target (GsfOpenPkgRel const *rel)
 }
 
 /**
- * gsf_open_pkg_rel_get_type :
- * @rel : #GsfOpenPkgRel
- *
+ * gsf_open_pkg_rel_get_type:
+ * @rel: #GsfOpenPkgRel
+ * 
  * Returns: const pointer to @rel's type.
  **/
 char const *
@@ -195,12 +195,12 @@ gsf_open_pkg_get_rels (GsfInput *opkg)
 }
 
 /**
- * gsf_open_pkg_open_rel :
- * @opkg : #GsfInput
- * @rel : #GsfOpenPkgRel
- * @err : #GError.
+ * gsf_open_pkg_open_rel:
+ * @opkg: #GsfInput
+ * @rel: #GsfOpenPkgRel
+ * @err: #GError.
  *
- * Returns: a new #GsfInput which the called needs to unref, or %NULL and sets @err
+ * Returns: (transfer full): a new #GsfInput which the called needs to unref, or %NULL and sets @err
  **/
 GsfInput *
 gsf_open_pkg_open_rel (GsfInput *opkg, GsfOpenPkgRel const *rel,
@@ -251,15 +251,17 @@ gsf_open_pkg_open_rel (GsfInput *opkg, GsfOpenPkgRel const *rel,
 }
 
 /**
- * gsf_open_pkg_lookup_rel_by_type :
- * @opkg : #GsfInput
- * @type : target
+ * gsf_open_pkg_lookup_rel_by_type: (skip)
+ * @opkg: #GsfInput
+ * @type: target
  *
  * New in 1.14.6
  *
  * Finds _a_ relation of @opkg with @type (no order is guaranteed)
+ * 
+ * NOTE: skipping because gsf_open_pkg_rel_get_type() does not return a GType.
  *
- * Returns: A #GsfOpenPkgRel or %NULL
+ * Returns: (transfer none): A #GsfOpenPkgRel or %NULL
  **/
 GsfOpenPkgRel *
 gsf_open_pkg_lookup_rel_by_type (GsfInput *opkg, char const *type)
@@ -269,15 +271,17 @@ gsf_open_pkg_lookup_rel_by_type (GsfInput *opkg, char const *type)
 }
 
 /**
- * gsf_open_pkg_open_rel_by_id :
- * @opkg : #GsfInput
- * @id :
+ * gsf_open_pkg_lookup_rel_by_id: (skip)
+ * @opkg: #GsfInput
+ * @id: identifier.
  *
  * New in 1.14.6
  *
  * Finds @opkg's relation with @id
+ * 
+ * NOTE: skipping because gsf_open_pkg_rel_get_type() does not return a GType.
  *
- * Returns: A #GsfOpenPkgRel or %NULL
+ * Returns: (transfer none): A #GsfOpenPkgRel or %NULL
  **/
 GsfOpenPkgRel *
 gsf_open_pkg_lookup_rel_by_id (GsfInput *opkg, char const *id)
@@ -302,9 +306,9 @@ cb_foreach_rel (G_GNUC_UNUSED gpointer id,
 
 /**
  * gsf_open_pkg_foreach_rel:
- * @opkg : #GsfInput
- * @func : #GsfOpenPkgIter
- * @user_data : gpointer
+ * @opkg: #GsfInput
+ * @func: (scope call): #GsfOpenPkgIter
+ * @user_data: gpointer
  *
  * New in 1.14.9
  *
@@ -327,16 +331,16 @@ gsf_open_pkg_foreach_rel (GsfInput *opkg,
 }
 
 /**
- * gsf_open_pkg_open_rel_by_id :
- * @opkg : #GsfInput
- * @id : target id
- * @err : optionally %NULL
+ * gsf_open_pkg_open_rel_by_id:
+ * @opkg: #GsfInput
+ * @id: target id
+ * @err: optionally %NULL
  *
  * New in 1.14.7
  *
  * Open @opkg's relation @id
  *
- * Returns: A new GsfInput or %NULL, and sets @err if possible.
+ * Returns: (transfer full): A new GsfInput or %NULL, and sets @err if possible.
  **/
 GsfInput *
 gsf_open_pkg_open_rel_by_id (GsfInput *opkg, char const *id, GError **err)
@@ -354,16 +358,16 @@ gsf_open_pkg_open_rel_by_id (GsfInput *opkg, char const *id, GError **err)
 }
 
 /**
- * gsf_open_pkg_open_rel_by_type :
- * @opkg : #GsfInput
- * @type : target type
- * @err : optionally %NULL
+ * gsf_open_pkg_open_rel_by_type:
+ * @opkg: #GsfInput
+ * @type: target type
+ * @err: optionally %NULL
  *
  * New in 1.14.9
  *
  * Open one of @opkg's relationships with type= type 
  *
- * Returns: A new GsfInput or %NULL, and sets @err if possible.
+ * Returns: (transfer full): A new GsfInput or %NULL, and sets @err if possible.
  **/
 GsfInput *
 gsf_open_pkg_open_rel_by_type (GsfInput *opkg, char const *type, GError **err)
@@ -382,11 +386,11 @@ gsf_open_pkg_open_rel_by_type (GsfInput *opkg, char const *type, GError **err)
 }
 
 /**
- * gsf_open_pkg_parse_rel_by_id :
- * @xin : #GsfXMLIn
- * @id : target id
- * @dtd : #GsfXMLInNode
- * @ns : #GsfXMLInNS
+ * gsf_open_pkg_parse_rel_by_id:
+ * @xin: #GsfXMLIn
+ * @id: target id
+ * @dtd: #GsfXMLInNode
+ * @ns: #GsfXMLInNS
  *
  * Convenience function to parse a related part.
  *
@@ -427,7 +431,15 @@ gsf_open_pkg_parse_rel_by_id (GsfXMLIn *xin, char const *id,
 }
 
 /* DEPRECATED in 1.14.6 */
+/**
+ * gsf_open_pkg_get_rel_by_type: (skip) (Deprecated: 1.14.6)
+ *
+ */
 GsfInput *gsf_open_pkg_get_rel_by_type (GsfInput *opkg, char const *type) { return gsf_open_pkg_open_rel_by_type (opkg, type, NULL); }
+/**
+ * gsf_open_pkg_get_rel_by_id: (skip) (Deprecated: 1.14.6)
+ *
+ */
 GsfInput *gsf_open_pkg_get_rel_by_id   (GsfInput *opkg, char const *id)   { return gsf_open_pkg_open_rel_by_id (opkg, id, NULL); }
 
 /*************************************************************/
@@ -728,8 +740,8 @@ GSF_CLASS (GsfOutfileOpenPkg, gsf_outfile_open_pkg,
 	   GSF_OUTFILE_TYPE)
 
 /**
- * gsf_outfile_open_pkg_new :
- * @sink : #GsfOutfile
+ * gsf_outfile_open_pkg_new:
+ * @sink: #GsfOutfile
  *
  * Convenience routine to create a GsfOutfileOpenPkg inside @sink.
  *
@@ -744,9 +756,9 @@ gsf_outfile_open_pkg_new (GsfOutfile *sink)
 }
 
 /**
- * gsf_outfile_open_pkg_set_sink :
- * @open_pkg : #GsfOutfileOpenPkg
- * @sink : #GsfOutput
+ * gsf_outfile_open_pkg_set_sink:
+ * @open_pkg: #GsfOutfileOpenPkg
+ * @sink: #GsfOutput
  *
  * Assigns a GsfOutput (@sink) to store the package into.
  **/
@@ -761,9 +773,9 @@ gsf_outfile_open_pkg_set_sink (GsfOutfileOpenPkg *open_pkg, GsfOutput *sink)
 }
 
 /**
- * gsf_outfile_open_pkg_set_content_type :
- * @open_pkg : #GsfOutfileOpenPkg
- * @content_type :
+ * gsf_outfile_open_pkg_set_content_type:
+ * @open_pkg: #GsfOutfileOpenPkg
+ * @content_type:
  *
  **/
 void
@@ -795,9 +807,9 @@ gsf_outfile_open_pkg_create_rel (GsfOutfileOpenPkg *parent,
 
 /**
  * gsf_outfile_open_pkg_relate:
- * @child : #GsfOutfileOpenPkg
- * @parent : #GsfOutfileOpenPkg
- * @type : target type
+ * @child: #GsfOutfileOpenPkg
+ * @parent: #GsfOutfileOpenPkg
+ * @type: target type
  *
  * Create a relationship between @child and @parent of @type.
  *
@@ -843,16 +855,16 @@ found:
 
 /**
  * gsf_outfile_open_pkg_add_rel:
- * @dir : #GsfOutfile
- * @name : target name
- * @content_type : non-%NULL content type
- * @parent : #GsfOutfile
- * @type : target type
+ * @dir: #GsfOutfile
+ * @name: target name
+ * @content_type: non-%NULL content type
+ * @parent: #GsfOutfile
+ * @type: target type
  *
  * A convenience wrapper to create a child in @dir of @content_type then create
  * a @type relation to @parent
  *
- * Returns: the new part.
+ * Returns: (transfer full): the new part.
  **/
 GsfOutput *
 gsf_outfile_open_pkg_add_rel (GsfOutfile *dir,
@@ -870,14 +882,14 @@ gsf_outfile_open_pkg_add_rel (GsfOutfile *dir,
 }
 
 /**
- * gsf_outfile_open_pkg_add_extern_rel :
- * @parent : #GsfOutfileOpenPkg
- * @target : target type
- * @content_type : target content
+ * gsf_outfile_open_pkg_add_extern_rel:
+ * @parent: #GsfOutfileOpenPkg
+ * @target: target type
+ * @content_type: target content
  *
  * Add an external relation to @parent.
  *
- * Returns: The id of the relation.  The string is managed by the parent and
+ * Returns: (transfer none): The id of the relation.  The string is managed by the parent and
  * 	should not be changed or freed by the caller.
  **/
 char const *
diff --git a/gsf/gsf-opendoc-utils.c b/gsf/gsf-opendoc-utils.c
index ceaa039..97316c6 100644
--- a/gsf/gsf-opendoc-utils.c
+++ b/gsf/gsf-opendoc-utils.c
@@ -264,7 +264,7 @@ od_meta_user_defined_end (GsfXMLIn *xin, G_GNUC_UNUSED GsfXMLBlob *blob)
 			if (g_str_has_prefix (mi->name, "GSF_DOCPROP_VECTOR:")) {
 				gchar *true_name = strchr (mi->name + 19, ':');
 				if (true_name != NULL && *(++true_name) != 0) {
-					GsfDocProp *prop = gsf_doc_meta_data_lookup 
+					GsfDocProp *prop = gsf_doc_meta_data_lookup
 						(mi->md, true_name);
 					if (prop == NULL) {
 						GsfDocPropVector *vector = gsf_docprop_vector_new ();
@@ -286,13 +286,13 @@ od_meta_user_defined_end (GsfXMLIn *xin, G_GNUC_UNUSED GsfXMLBlob *blob)
 							vector = gsf_value_get_docprop_varray (new);
 							g_value_array_append (vector, res);
 							gsf_doc_prop_set_val (prop, new);
-						} else 
+						} else
 							g_printerr (_("Property \"%s\" used for "
 								      "multiple types!"), true_name);
 						g_value_unset (res);
-						g_free (res);						
+						g_free (res);
 					}
-				
+
 					g_free (mi->name);
 					mi->name = NULL;
 					return;
@@ -362,9 +362,9 @@ gsf_opendoc_metadata_subtree_free (G_GNUC_UNUSED GsfXMLIn *xin, gpointer old_sta
 static GsfXMLInDoc *doc_subtree = NULL;
 
 /**
- * gsf_opendoc_metadata_subtree :
- * @doc : #GsfXMLInDoc
- * @md  : #GsfDocMetaData
+ * gsf_opendoc_metadata_subtree:
+ * @doc: #GsfXMLInDoc
+ * @md: #GsfDocMetaData
  *
  * Extend @xin so that it can parse a subtree in OpenDoc metadata format
  **/
@@ -386,8 +386,8 @@ gsf_opendoc_metadata_subtree (GsfXMLIn *xin, GsfDocMetaData *md)
 }
 
 /**
- * gsf_opendoc_metadata_subtree_internal :
- * @doc : #GsfXMLInDoc
+ * gsf_opendoc_metadata_subtree_internal:
+ * @doc: #GsfXMLInDoc
  *
  * Extend @xin so that it can parse a subtree in OpenDoc metadata format
  * The current user_state must be a  GsfOOMetaIn!
@@ -408,9 +408,9 @@ static GsfXMLInNode const gsf_opendoc_meta_dtd[] = {
 };
 
 /**
- * gsf_opendoc_metadata_read :
- * @input : #GsfInput
- * @md    : #GsfDocMetaData
+ * gsf_opendoc_metadata_read:
+ * @input: #GsfInput
+ * @md: #GsfDocMetaData
  *
  * Read an OpenDocument metadata stream from @input and store the properties
  * into @md.  Overwrite any existing properties with the same id.
@@ -521,12 +521,12 @@ meta:object-count
 static void
 gsf_xml_out_add_gvalue_for_odf (GsfXMLOut *xout, char const *id, GValue const *val)
 {
-		if (G_VALUE_TYPE (val) == G_TYPE_BOOLEAN) 
-			gsf_xml_out_add_cstr 
+		if (G_VALUE_TYPE (val) == G_TYPE_BOOLEAN)
+			gsf_xml_out_add_cstr
 				(xout, id,
 				 g_value_get_boolean (val) ? "true" : "false");
 			else
-				gsf_xml_out_add_gvalue (xout, id, val);	
+				gsf_xml_out_add_gvalue (xout, id, val);
 }
 
 
@@ -535,15 +535,15 @@ meta_write_props_user_defined (char const *prop_name, GValue const *val, GsfXMLO
 {
 	GType t;
 	char const *type_name = NULL;
-	
+
 	gsf_xml_out_start_element (output, "meta:user-defined");
 	gsf_xml_out_add_cstr (output, "meta:name", prop_name);
-	
+
 	if (NULL == val) {
 			gsf_xml_out_end_element (output);
 			return;
 	}
-	
+
 	t = G_VALUE_TYPE (val);
 	switch (t) {
 	case G_TYPE_CHAR:
@@ -564,7 +564,7 @@ meta_write_props_user_defined (char const *prop_name, GValue const *val, GsfXMLO
 	case G_TYPE_DOUBLE:
 		type_name = "float";
 		break;
-		
+
 	default:
 		if (GSF_TIMESTAMP_TYPE == t)
 			type_name = "date";
@@ -619,9 +619,9 @@ meta_write_props (char const *prop_name, GsfDocProp *prop, GsfXMLOut *output)
 
 			for (i = 0; i < num_values; i++) {
 				GValue	*v;
-				char    *new_name = g_strdup_printf 
+				char    *new_name = g_strdup_printf
 					("GSF_DOCPROP_VECTOR:%.4i:%s", i, prop_name);
-				
+
 				v = g_value_array_get_nth (vector, i);
 				meta_write_props_user_defined (new_name, v, output);
 				g_free (new_name);
@@ -758,7 +758,7 @@ gsf_odf_out_class_init (GObjectClass *gobject_class)
 				   G_MAXINT,
 				   100,
 				   GSF_PARAM_STATIC |
-				   G_PARAM_READWRITE | 
+				   G_PARAM_READWRITE |
 				   G_PARAM_CONSTRUCT_ONLY));
 
 	g_type_class_add_private (gobject_class, sizeof (GsfODFOutPrivate));
diff --git a/gsf/gsf-opendoc-utils.h b/gsf/gsf-opendoc-utils.h
index 8c3d50b..fe29190 100644
--- a/gsf/gsf-opendoc-utils.h
+++ b/gsf/gsf-opendoc-utils.h
@@ -43,11 +43,12 @@ typedef struct {
 	void (*_gsf_reserved4) (void);
 } GsfODFOutClass;
 
-typedef struct _GsfODFOut {
+typedef struct _GsfODFOut GsfODFOut;
+struct _GsfODFOut {
 	GsfXMLOut base;
 	/*< private >*/
 	struct _GsfODFOutPrivate *priv;
-} GsfODFOut;
+};
 
 #define GSF_ODF_OUT_TYPE	(gsf_odf_out_get_type ())
 #define GSF_ODF_OUT(o)		(G_TYPE_CHECK_INSTANCE_CAST ((o), GSF_ODF_OUT_TYPE, GsfODFOut))
diff --git a/gsf/gsf-outfile-msole.c b/gsf/gsf-outfile-msole.c
index 1681cac..4f362cb 100644
--- a/gsf/gsf-outfile-msole.c
+++ b/gsf/gsf-outfile-msole.c
@@ -698,10 +698,10 @@ compute_shift (unsigned value)
 }
 
 /**
- * gsf_outfile_msole_new_full :
- * @sink : a #GsfOutput to hold the OLE2 file.
- * @bb_size : size of large blocks.
- * @sb_size : size of small blocks.
+ * gsf_outfile_msole_new_full:
+ * @sink: a #GsfOutput to hold the OLE2 file.
+ * @bb_size: size of large blocks.
+ * @sb_size: size of small blocks.
  *
  * Creates the root directory of an MS OLE file and manages the addition of
  * children.
@@ -776,8 +776,8 @@ gsf_outfile_msole_new_full (GsfOutput *sink, guint bb_size, guint sb_size)
 }
 
 /**
- * gsf_outfile_msole_new :
- * @sink : a #GsfOutput to hold the OLE2 file
+ * gsf_outfile_msole_new:
+ * @sink: a #GsfOutput to hold the OLE2 file
  *
  * Creates the root directory of an MS OLE file and manages the addition of
  * children.
@@ -794,7 +794,7 @@ gsf_outfile_msole_new (GsfOutput *sink)
 }
 
 /**
- * gsf_outfile_msole_set_class_id :
+ * gsf_outfile_msole_set_class_id:
  * @ole: a #GsfOutfileMSOle
  * @clsid: 16 byte identifier (often a GUID in MS Windows apps)
  *
diff --git a/gsf/gsf-outfile-stdio.c b/gsf/gsf-outfile-stdio.c
index 607e03e..322baaf 100644
--- a/gsf/gsf-outfile-stdio.c
+++ b/gsf/gsf-outfile-stdio.c
@@ -105,9 +105,9 @@ GSF_CLASS (GsfOutfileStdio, gsf_outfile_stdio,
 	   GSF_OUTFILE_TYPE)
 
 /**
- * gsf_outfile_stdio_new_valist :
- * @root : root directory in utf8.
- * @err	 : optionally NULL.
+ * gsf_outfile_stdio_new_valist:
+ * @root: root directory in utf8.
+ * @err: optionally NULL.
  * @first_property_name: name of first property to set
  * @var_args: a %NULL-terminated #va_list
  *
@@ -141,11 +141,11 @@ gsf_outfile_stdio_new_valist (char const *root, GError **err,
 }
 
 /**
- * gsf_outfile_stdio_new_full :
- * @root : root directory in utf8.
- * @err	 : optionally NULL.
+ * gsf_outfile_stdio_new_full:
+ * @root: root directory in utf8.
+ * @err: optionally NULL.
  * @first_property_name: name of first property to set
- * @Varargs: value of first property, followed by more properties,
+ * @...: value of first property, followed by more properties,
  * 		%NULL-terminated
  *
  * Returns: a new outfile or NULL.
@@ -166,9 +166,9 @@ gsf_outfile_stdio_new_full (char const *root, GError **err,
 }
 
 /**
- * gsf_outfile_stdio_new :
- * @root : root directory in utf8.
- * @err	 : optionally NULL.
+ * gsf_outfile_stdio_new:
+ * @root: root directory in utf8.
+ * @err: optionally NULL.
  *
  * Returns: a new outfile or NULL.
  **/
diff --git a/gsf/gsf-outfile-zip.c b/gsf/gsf-outfile-zip.c
index 315e809..98d8158 100644
--- a/gsf/gsf-outfile-zip.c
+++ b/gsf/gsf-outfile-zip.c
@@ -737,7 +737,7 @@ GSF_CLASS (GsfOutfileZip, gsf_outfile_zip,
 	   GSF_OUTFILE_TYPE)
 
 /**
- * gsf_outfile_zip_new :
+ * gsf_outfile_zip_new:
  * @sink: a #GsfOutput to hold the ZIP file
  * @err: Location to store error, or %NULL; currently unused.
  *
diff --git a/gsf/gsf-outfile.c b/gsf/gsf-outfile.c
index 0859679..9efec53 100644
--- a/gsf/gsf-outfile.c
+++ b/gsf/gsf-outfile.c
@@ -26,12 +26,12 @@
 #define GET_CLASS(instance) G_TYPE_INSTANCE_GET_CLASS (instance, GSF_OUTFILE_TYPE, GsfOutfileClass)
 
 /**
- * gsf_outfile_new_child :
- * @outfile : A #GsfOutfile
- * @name : The name of the new child to create
- * @is_dir : %TRUE to create a directory, %FALSE to create a plain file
+ * gsf_outfile_new_child:
+ * @outfile: A #GsfOutfile
+ * @name: The name of the new child to create
+ * @is_dir: %TRUE to create a directory, %FALSE to create a plain file
  *
- * Returns: a newly created child
+ * Returns: (transfer full): a newly created child
  **/
 GsfOutput *
 gsf_outfile_new_child (GsfOutfile *outfile,
@@ -41,14 +41,14 @@ gsf_outfile_new_child (GsfOutfile *outfile,
 }
 
 /**
- * gsf_outfile_new_child_full :
- * @outfile : A #GsfOutfile
- * @name : The name of the new child to create
- * @is_dir : TRUE to create a directory, FALSE to create a plain file
- * @first_property_name :
- * @Varargs :
+ * gsf_outfile_new_child_full:
+ * @outfile: A #GsfOutfile
+ * @name: The name of the new child to create
+ * @is_dir: TRUE to create a directory, FALSE to create a plain file
+ * @first_property_name:
+ * @...:
  *
- * Returns: a newly created child
+ * Returns: (transfer full): a newly created child
  **/
 GsfOutput *
 gsf_outfile_new_child_full (GsfOutfile *outfile,
@@ -69,6 +69,16 @@ gsf_outfile_new_child_full (GsfOutfile *outfile,
 	return res;
 }
 
+/**
+ * gsf_outfile_new_child_varg:
+ * @outfile: A #GsfOutfile
+ * @name: The name of the new child to create
+ * @is_dir: TRUE to create a directory, FALSE to create a plain file
+ * @first_property_name:
+ * @args:
+ *
+ * Returns: (transfer full): a newly created child
+ **/
 GsfOutput *
 gsf_outfile_new_child_varg (GsfOutfile *outfile,
 			    char const *name, gboolean is_dir,
diff --git a/gsf/gsf-output-bzip.c b/gsf/gsf-output-bzip.c
index 934bf83..acac074 100644
--- a/gsf/gsf-output-bzip.c
+++ b/gsf/gsf-output-bzip.c
@@ -235,9 +235,9 @@ GSF_CLASS (GsfOutputBzip, gsf_output_bzip,
 	   GSF_OUTPUT_TYPE)
 
 /**
- * gsf_output_bzip_new :
- * @sink : The underlying data source.
- * @err	   : optionally %NULL.
+ * gsf_output_bzip_new:
+ * @sink: The underlying data source.
+ * @err: optionally %NULL.
  *
  * Adds a reference to @sink.
  *
diff --git a/gsf/gsf-output-gzip.c b/gsf/gsf-output-gzip.c
index 5e71750..8edd195 100644
--- a/gsf/gsf-output-gzip.c
+++ b/gsf/gsf-output-gzip.c
@@ -106,9 +106,9 @@ gzip_output_header (GsfOutputGZip *gzip)
 }
 
 /**
- * gsf_output_gzip_new :
- * @sink : The underlying data source.
- * @err	   : optionally %NULL.
+ * gsf_output_gzip_new:
+ * @sink: The underlying data source.
+ * @err: optionally %NULL.
  *
  * Adds a reference to @sink.
  *
diff --git a/gsf/gsf-output-iconv.c b/gsf/gsf-output-iconv.c
index 4a2a70f..7f31040 100644
--- a/gsf/gsf-output-iconv.c
+++ b/gsf/gsf-output-iconv.c
@@ -52,10 +52,10 @@ enum {
 };
 
 /**
- * gsf_output_iconv_new :
- * @sink : The underlying data source.
- * @dst : The target character set.
- * @src : The source character set.
+ * gsf_output_iconv_new:
+ * @sink: The underlying data source.
+ * @dst: The target character set.
+ * @src: The source character set.
  *
  * Adds a reference to @sink.
  *
diff --git a/gsf/gsf-output-iochannel.c b/gsf/gsf-output-iochannel.c
index 5c2c480..c3785ae 100644
--- a/gsf/gsf-output-iochannel.c
+++ b/gsf/gsf-output-iochannel.c
@@ -35,7 +35,7 @@ typedef struct {
 } GsfOutputIOChannelClass;
 
 /**
- * gsf_output_iochannel_new :
+ * gsf_output_iochannel_new:
  * @channel: A #GIOChannel
  *
  * Returns: a new file or NULL.
diff --git a/gsf/gsf-output-memory.c b/gsf/gsf-output-memory.c
index df29676..97bea4f 100644
--- a/gsf/gsf-output-memory.c
+++ b/gsf/gsf-output-memory.c
@@ -40,7 +40,7 @@ typedef struct {
 } GsfOutputMemoryClass;
 
 /**
- * gsf_output_memory_new :
+ * gsf_output_memory_new:
  *
  * Returns: a new file or %NULL.
  **/
@@ -185,8 +185,8 @@ gsf_output_memory_class_init (GObjectClass *gobject_class)
 }
 
 /**
- * gsf_output_memory_get_bytes :
- * @mem : the output device.
+ * gsf_output_memory_get_bytes:
+ * @mem: the output device.
  *
  * Returns: The data that has been written to @mem, or %null
  **/
diff --git a/gsf/gsf-output-stdio.c b/gsf/gsf-output-stdio.c
index 9bf32dc..f596a86 100644
--- a/gsf/gsf-output-stdio.c
+++ b/gsf/gsf-output-stdio.c
@@ -529,11 +529,11 @@ gsf_output_stdio_new_valist (char const *filename, GError **err,
 }
 
 /**
- * gsf_output_stdio_new_full :
- * @filename : name of file to create or replace.
- * @err	     : optionally %NULL.
- * @first_property_name : %NULL terminated list of properties
- * @Varargs :
+ * gsf_output_stdio_new_full:
+ * @filename: name of file to create or replace.
+ * @err: optionally %NULL.
+ * @first_property_name: %NULL terminated list of properties
+ * @...:
  *
  * Returns: a new file or %NULL.
  **/
@@ -552,9 +552,9 @@ gsf_output_stdio_new_full (char const *filename, GError **err,
 }
 
 /**
- * gsf_output_stdio_new :
- * @filename : name of file to create or replace.
- * @err	     : optionally %NULL.
+ * gsf_output_stdio_new:
+ * @filename: name of file to create or replace.
+ * @err: optionally %NULL.
  *
  * Returns: a new file or %NULL.
  **/
@@ -565,10 +565,10 @@ gsf_output_stdio_new (char const *filename, GError **err)
 }
 
 /**
- * gsf_output_stdio_new_FILE :
- * @filename  : The filename corresponding to @file.
- * @file      : an existing stdio <type>FILE</type> *
- * @keep_open : Should @file be closed when the wrapper is closed
+ * gsf_output_stdio_new_FILE:
+ * @filename: The filename corresponding to @file.
+ * @file: an existing stdio <type>FILE</type> *
+ * @keep_open: Should @file be closed when the wrapper is closed
  *
  * Assumes ownership of @file.  If @keep_open is true, ownership reverts
  * to caller when the GsfObject is closed.
diff --git a/gsf/gsf-output-transaction.c b/gsf/gsf-output-transaction.c
index eaf044a..d632e2f 100644
--- a/gsf/gsf-output-transaction.c
+++ b/gsf/gsf-output-transaction.c
@@ -61,7 +61,7 @@ static GsfOutputClass *parent_class;
 /********************************************************************************/
 
 /**
- * gsf_output_transaction_commit :
+ * gsf_output_transaction_commit:
  * @output: the transaction you wish to commit
  *
  * "Atomically" commits your data changes. After committing, it closes the
@@ -101,7 +101,7 @@ gsf_output_transaction_commit (GsfOutputTransaction * output)
 }
 
 /**
- * gsf_output_transaction_commit :
+ * gsf_output_transaction_commit:
  * @output: the transaction you wish to abort. After aborting, it closes the
  * output. No more writes, seeks, etc... are valid on this object.
  *
@@ -122,7 +122,7 @@ gsf_output_transaction_abort (GsfOutputTransaction * output)
 }
 
 /**
- * gsf_output_transaction_new_named :
+ * gsf_output_transaction_new_named:
  * @wrapped: The sink you want to write to
  * @name: The non-null name for this transaction
  *
@@ -152,7 +152,7 @@ gsf_output_transaction_new_named (GsfOutput *wrapped, char const *name)
 }
 
 /**
- * gsf_output_transaction_new :
+ * gsf_output_transaction_new:
  * @wrapped: The sink you want to write to
  *
  * Returns: The new anonymous transaction output object
diff --git a/gsf/gsf-output.c b/gsf/gsf-output.c
index 410aec1..b3de585 100644
--- a/gsf/gsf-output.c
+++ b/gsf/gsf-output.c
@@ -162,7 +162,7 @@ GSF_CLASS_ABSTRACT (GsfOutput, gsf_output,
 		    G_TYPE_OBJECT)
 
 /**
- * gsf_output_name :
+ * gsf_output_name:
  * @output: #GsfOutput
  *
  * Give the name of @output.
@@ -177,10 +177,10 @@ gsf_output_name (GsfOutput const *output)
 }
 
 /**
- * gsf_output_container :
- * @output :
+ * gsf_output_container:
+ * @output:
  *
- * Returns: but does not add a reference to @output's container.
+ * Returns: (transfer none): but does not add a reference to @output's container.
  * 	Potentially %NULL
  **/
 GsfOutfile *
@@ -191,7 +191,7 @@ gsf_output_container (GsfOutput const *output)
 }
 
 /**
- * gsf_output_size :
+ * gsf_output_size:
  * @output: #GsfOutput
  *
  * Determine the size of the output stream @output.
@@ -206,7 +206,7 @@ gsf_output_size (GsfOutput *output)
 }
 
 /**
- * gsf_output_close :
+ * gsf_output_close:
  * @output: #GsfOutput
  *
  * Close a stream.
@@ -232,7 +232,7 @@ gsf_output_close (GsfOutput *output)
 }
 
 /**
- * gsf_output_is_closed :
+ * gsf_output_is_closed:
  * @output: #GsfOutput
  *
  * Returns: %TRUE if @output has already been closed.
@@ -245,8 +245,8 @@ gsf_output_is_closed (GsfOutput const *output)
 }
 
 /**
- * gsf_output_tell :
- * @output : #GsfOutput
+ * gsf_output_tell:
+ * @output: #GsfOutput
  *
  * Tell the current position in @output, similar to
  * <citerefentry><refentrytitle>ftell</refentrytitle>
@@ -263,10 +263,10 @@ gsf_output_tell	(GsfOutput *output)
 }
 
 /**
- * gsf_output_seek :
- * @output : #GsfOutput
- * @offset : Relative amount to reposition
- * @whence : What the offset is relative to.
+ * gsf_output_seek:
+ * @output: #GsfOutput
+ * @offset: Relative amount to reposition
+ * @whence: What the offset is relative to.
  *
  * Reposition in output stream @output. @whence specifies what the offset is
  * relative to: the beginning of the stream (%G_SEEK_SET), current position in
@@ -330,10 +330,10 @@ gsf_output_inc_cur_offset (GsfOutput *output, gsf_off_t num_bytes)
 }
 
 /**
- * gsf_output_write :
- * @output : Output stream
- * @num_bytes : Number of bytes to write
- * @data : Data to write.
+ * gsf_output_write:
+ * @output: Output stream
+ * @num_bytes: Number of bytes to write
+ * @data: Data to write.
  *
  * Write @num_bytes of @data to @output.
  *
@@ -355,7 +355,7 @@ gsf_output_write (GsfOutput *output,
 }
 
 /**
- * gsf_output_error :
+ * gsf_output_error:
  * @output:
  *
  * Returns: the last error logged on the output, or %NULL.
@@ -368,7 +368,7 @@ gsf_output_error (GsfOutput const *output)
 }
 
 /**
- * gsf_output_set_name :
+ * gsf_output_set_name:
  * @output: #GsfOutput
  * @name: the new name
  *
@@ -392,9 +392,9 @@ gsf_output_set_name (GsfOutput *output, char const *name)
 }
 
 /**
- * gsf_output_set_name_from_filename :
- * @output : the output stream
- * @filename : the (fs-sys encoded) filename
+ * gsf_output_set_name_from_filename:
+ * @output: the output stream
+ * @filename: the (fs-sys encoded) filename
  *
  * <note>This is a utility routine that should only be used by derived
  * outputs.</note>
@@ -418,7 +418,7 @@ gsf_output_set_name_from_filename (GsfOutput *output, char const *filename)
 }
 
 /**
- * gsf_output_set_container :
+ * gsf_output_set_container:
  * @output: #GsfOutput
  * @container: #GsfOutfile
  *
@@ -441,11 +441,11 @@ gsf_output_set_container (GsfOutput *output, GsfOutfile *container)
 }
 
 /**
- * gsf_output_set_error :
+ * gsf_output_set_error:
  * @output: #GsfOutput
  * @code: The error id
  * @format: printf style format string
- * @Varargs: arguments for @format
+ * @...: arguments for @format
  *
  * <note>This is a utility routine that should only be used by derived
  * outputs.</note>
@@ -486,7 +486,7 @@ cb_output_unwrap (GsfOutput *wrapee, G_GNUC_UNUSED GObject *wrapper)
 }
 
 /**
- * gsf_output_wrap :
+ * gsf_output_wrap:
  * @wrapper:
  * @wrapee:
  *
@@ -510,7 +510,7 @@ gsf_output_wrap (GObject *wrapper, GsfOutput *wrapee)
 }
 
 /**
- * gsf_output_unwrap :
+ * gsf_output_unwrap:
  * @wrapper:
  * @wrapee:
  *
@@ -538,10 +538,10 @@ gsf_output_error_id (void)
 }
 
 /**
- * gsf_output_printf :
- * @output : A #GsfOutput
- * @format : The printf-style format string
- * @Varargs : the arguments for @format
+ * gsf_output_printf:
+ * @output: A #GsfOutput
+ * @format: The printf-style format string
+ * @...: the arguments for @format
  *
  * Output @Varargs to @output using the format string @format, similar to
  * <citerefentry><refentrytitle>printf</refentrytitle>
@@ -562,10 +562,10 @@ gsf_output_printf (GsfOutput *output, char const *format, ...)
 }
 
 /**
- * gsf_output_vprintf :
- * @output : A #GsfOutput
- * @format : The printf-style format string
- * @args : the arguments for @format
+ * gsf_output_vprintf:
+ * @output: A #GsfOutput
+ * @format: The printf-style format string
+ * @args: the arguments for @format
  *
  * Output @args to @output using the format string @format, similar to
  * <citerefentry><refentrytitle>vprintf</refentrytitle>
diff --git a/gsf/gsf-structured-blob.c b/gsf/gsf-structured-blob.c
index 71b086d..03ac789 100644
--- a/gsf/gsf-structured-blob.c
+++ b/gsf/gsf-structured-blob.c
@@ -192,13 +192,13 @@ GSF_CLASS (GsfStructuredBlob, gsf_structured_blob,
 	   GSF_INFILE_TYPE)
 
 /**
- * gsf_structured_blob_read :
+ * gsf_structured_blob_read:
  * @input: An input (potentially a GsfInfile) holding the blob
  *
  * Create a tree of binary blobs with unknown content from a #GsfInput or
  * #GsfInfile and store it in a newly created #GsfStructuredBlob.
  *
- * Returns: a new #GsfStructuredBlob object which the caller is responsible for.
+ * Returns: (transfer full): a new #GsfStructuredBlob object which the caller is responsible for.
  **/
 GsfStructuredBlob *
 gsf_structured_blob_read (GsfInput *input)
@@ -259,7 +259,7 @@ gsf_structured_blob_read (GsfInput *input)
 }
 
 /**
- * gsf_structured_blob_write :
+ * gsf_structured_blob_write:
  * @blob: #GsfStructuredBlob
  * @container: #GsfOutfile
  *
diff --git a/gsf/gsf-timestamp.c b/gsf/gsf-timestamp.c
index 1850387..02e338d 100644
--- a/gsf/gsf-timestamp.c
+++ b/gsf/gsf-timestamp.c
@@ -76,8 +76,8 @@ gsf_timestamp_copy (GsfTimestamp const *stamp)
 }
 
 /**
- * gsf_timestamp_free :
- * @stamp : timestamp to be freed
+ * gsf_timestamp_free:
+ * @stamp: timestamp to be freed
  *
  * Releases the memory in use for @stamp (if any).
  **/
@@ -119,9 +119,9 @@ static time_t gmt_to_local_win32(void)
 #endif
 
 /**
- * gsf_timestamp_from_string :
- * @spec : The string to parse
- * @stamp : #GsfTimestamp
+ * gsf_timestamp_from_string:
+ * @spec: The string to parse
+ * @stamp: #GsfTimestamp
  *
  * Very simple parser for time stamps.  Currently requires a format of
  * 	'YYYY-MM-DDThh:mm:ss'
@@ -153,9 +153,9 @@ gsf_timestamp_from_string (char const *spec, GsfTimestamp *stamp)
 }
 
 /**
- * gsf_timestamp_parse :
- * @spec : The string to parse
- * @stamp : #GsfTimestamp
+ * gsf_timestamp_parse: (skip) (Deprecated)
+ * @spec: The string to parse
+ * @stamp: #GsfTimestamp
  *
  * Very simple parser for time stamps.  Currently requires a format of
  * 	'YYYY-MM-DDThh:mm:ss'
@@ -172,7 +172,7 @@ gsf_timestamp_parse (char const *spec, GsfTimestamp *stamp)
 }
 
 /**
- * gsf_timestamp_as_string :
+ * gsf_timestamp_as_string:
  * @stamp: timestamp to be converted.
  *
  * Produce a string representation (ISO 8601 format) of @stamp.
@@ -210,7 +210,7 @@ gsf_timestamp_hash (GsfTimestamp const *stamp)
 }
 
 /**
- * gsf_timestamp_equal :
+ * gsf_timestamp_equal:
  * @a: a timestamp
  * @b: another timestamp
  *
diff --git a/gsf/gsf-utils.c b/gsf/gsf-utils.c
index f655a2c..3a69ca6 100644
--- a/gsf/gsf-utils.c
+++ b/gsf/gsf-utils.c
@@ -125,7 +125,7 @@ DllMain (HINSTANCE hinstDLL, DWORD fdwReason, G_GNUC_UNUSED LPVOID lpvReserved)
 #endif
 
 /**
- * gsf_init :
+ * gsf_init:
  *
  * Initializes the GSF library
  **/
@@ -204,8 +204,8 @@ gsf_shutdown (void)
 #endif
 
 /**
- * gsf_init_dynamic :
- * @module : #GTypeModule.
+ * gsf_init_dynamic:
+ * @module: #GTypeModule.
  *
  * Initializes the GSF library and associates it with a type module @mod.
  **/
@@ -301,7 +301,7 @@ gsf_mem_dump_full (guint8 const *ptr, size_t len, gsf_off_t offset)
 }
 
 /**
- * gsf_mem_dump :
+ * gsf_mem_dump:
  * @ptr: memory area to be dumped.
  * @len: how many bytes will be dumped.
  *
@@ -314,7 +314,7 @@ gsf_mem_dump (guint8 const *ptr, size_t len)
 }
 
 /**
- * gsf_input_dump :
+ * gsf_input_dump:
  * @input: a #GsfInput
  * @dump_as_hex: If %TRUE, dump in hexidecmal format
  *
@@ -391,7 +391,7 @@ gsf_le_get_guint64 (void const *p)
 }
 
 /**
- * gsf_le_get_float :
+ * gsf_le_get_float:
  * @p: pointer to storage
  *
  * Interpret binary data as a float in little endian order.
@@ -435,7 +435,7 @@ gsf_le_get_float (void const *p)
 }
 
 /**
- * gsf_le_set_float :
+ * gsf_le_set_float:
  * @p: pointer to storage
  * @f: float to be stored
  *
@@ -472,7 +472,7 @@ gsf_le_set_float (void *p, float f)
 }
 
 /**
- * gsf_le_get_double :
+ * gsf_le_get_double:
  * @p: pointer to storage
  *
  * Interpret binary data as a double in little endian order.
@@ -520,7 +520,7 @@ gsf_le_get_double (void const *p)
 }
 
 /**
- * gsf_le_set_double :
+ * gsf_le_set_double:
  * @p: pointer to storage
  * @d: double to be stored
  *
@@ -590,8 +590,8 @@ gsf_extension_pointer (char const *path)
 }
 
 /**
- * gsf_iconv_close :
- * @handle : handle to be closed.
+ * gsf_iconv_close:
+ * @handle: handle to be closed.
  *
  * A utility wrapper to safely close an iconv handle.
  **/
@@ -629,11 +629,11 @@ gsf_filename_to_utf8 (char const *filename, gboolean quoted)
 }
 
 /**
- * gsf_base64_encode_close :
- * @in : Data to be encoded
- * @inlen : Length of data to be encoded
- * @break_lines : Whether to use line breaks
- * @out : Encoded data.
+ * gsf_base64_encode_close:
+ * @in: Data to be encoded
+ * @inlen: Length of data to be encoded
+ * @break_lines: Whether to use line breaks
+ * @out: Encoded data.
  * @state: holds the number of bits that are stored in @save
  * @save: leftover bits that have not yet been decoded
  *
@@ -655,13 +655,13 @@ gsf_base64_encode_close (guint8 const *in, size_t inlen,
 }
 
 /**
- * gsf_base64_encode_step :
- * @in : input stream
- * @len : max length of data to decode
- * @break_lines : Whether to use line breaks
- * @out : output stream
- * @state : holds the number of bits that are stored in @save
- * @save : leftover bits that have not yet been decoded
+ * gsf_base64_encode_step:
+ * @in: input stream
+ * @len: max length of data to decode
+ * @break_lines: Whether to use line breaks
+ * @out: output stream
+ * @state: holds the number of bits that are stored in @save
+ * @save: leftover bits that have not yet been decoded
  *
  * Performs an 'encode step', only encodes blocks of 3 characters from @in into
  * the output @out at a time, saves left-over state in @state and @save
@@ -697,9 +697,9 @@ gsf_base64_decode_step (guint8 const *in, size_t len, guint8 *out,
 }
 
 /**
- * gsf_base64_encode_simple :
- * @data : data stream
- * @len : max length of data to encode
+ * gsf_base64_encode_simple:
+ * @data: data stream
+ * @len: max length of data to encode
  *
  * Encodes data from @data back into @data using base64 encoding.
  *
@@ -724,9 +724,9 @@ gsf_base64_encode_simple (guint8 const *data, size_t len)
 }
 
 /**
- * gsf_base64_decode_simple :
- * @data : data stream
- * @len : max length of data to decode
+ * gsf_base64_decode_simple:
+ * @data: data stream
+ * @len: max length of data to decode
  *
  * Decodes a chunk of base64 encoded data from @data back into @data.
  *
diff --git a/gsf/gsf-zip-impl.h b/gsf/gsf-zip-impl.h
index dc187e2..3ffbd34 100644
--- a/gsf/gsf-zip-impl.h
+++ b/gsf/gsf-zip-impl.h
@@ -105,9 +105,13 @@ typedef struct {
 	GSList *children, *last_child;
 } GsfZipVDir;
 
+GType         gsf_zip_dirent_get_type (void);
 GsfZipDirent *gsf_zip_dirent_new  (void);
 void          gsf_zip_dirent_free (GsfZipDirent *dirent);
 
+GType       gsf_zip_vdir_get_type (void);
+GsfZipVDir *gsf_zip_vdir_new	(char const *name, gboolean is_directory,
+				 GsfZipDirent *dirent);
 GsfZipVDir *gsf_vdir_new	(char const *name, gboolean is_directory,
 				 GsfZipDirent *dirent);
 void	    gsf_vdir_free	(GsfZipVDir *vdir, gboolean free_dirent);
diff --git a/gsf/gsf-zip-utils.c b/gsf/gsf-zip-utils.c
index e9860b4..be0dbf5 100644
--- a/gsf/gsf-zip-utils.c
+++ b/gsf/gsf-zip-utils.c
@@ -51,8 +51,40 @@ gsf_zip_dirent_free (GsfZipDirent *dirent)
 	g_free (dirent);
 }
 
+static GsfZipDirent *
+gsf_zip_dirent_copy (GsfZipDirent *dirent)
+{
+	GsfZipDirent *res = g_new0 (GsfZipDirent, 1);
+	memcpy (res, dirent, sizeof (GsfZipDirent));
+	if (dirent->name)
+		res->name = g_strdup (dirent->name);
+	return res;
+}
+
+GType
+gsf_zip_dirent_get_type (void)
+{
+    static GType type = 0;
+
+    if (type == 0)
+	type = g_boxed_type_register_static
+	    ("GsfZipDirent",
+	     (GBoxedCopyFunc) gsf_zip_dirent_copy,
+	     (GBoxedFreeFunc) gsf_zip_dirent_free);
+
+    return type;
+}
+
+/**
+ * gsf_zip_vdir_new:
+ * @name:
+ * @is_directory:
+ * @dirent:
+ * 
+ * Returns: the newly created #GsfZipVDir.
+ */
 GsfZipVDir *
-gsf_vdir_new (char const *name, gboolean is_directory, GsfZipDirent *dirent)
+gsf_zip_vdir_new (char const *name, gboolean is_directory, GsfZipDirent *dirent)
 {
 	GsfZipVDir *vdir = g_new (GsfZipVDir, 1);
 
@@ -63,6 +95,20 @@ gsf_vdir_new (char const *name, gboolean is_directory, GsfZipDirent *dirent)
 	return vdir;
 }
 
+/**
+ * gsf_vdir_new: (skip) (Deprecated: 1.14.24)
+ * @name:
+ * @is_directory:
+ * @dirent:
+ * 
+ * Returns: the newly created #GsfZipVDir.
+ */
+GsfZipVDir *
+gsf_vdir_new (char const *name, gboolean is_directory, GsfZipDirent *dirent)
+{
+	return gsf_zip_vdir_new (name, is_directory, dirent);
+}
+
 void
 gsf_vdir_free (GsfZipVDir *vdir, gboolean free_dirent)
 {
@@ -81,6 +127,43 @@ gsf_vdir_free (GsfZipVDir *vdir, gboolean free_dirent)
 	g_free (vdir);
 }
 
+static GsfZipVDir *
+gsf_vdir_copy (GsfZipVDir *vdir)
+{
+	GsfZipVDir *res = g_new0 (GsfZipVDir, 1);
+	GSList *l;
+	/* it is not possible to add a ref_count without breaking the API,
+	 * so we need to really copy everything */
+	if (vdir->name)
+		res->name = g_strdup (vdir->name);
+	res->is_directory = vdir->is_directory;
+	if (vdir->dirent)
+		res->dirent = gsf_zip_dirent_copy (vdir->dirent);
+	for (l = vdir->children; l; l = l->next)
+		gsf_vdir_add_child (res, gsf_vdir_copy ((GsfZipVDir *)l->data));
+	return res;
+}
+
+static void
+gsf_vdir_destroy (GsfZipVDir *vdir)
+{
+	gsf_vdir_free (vdir, TRUE);
+}
+
+GType
+gsf_zip_vdir_get_type (void)
+{
+    static GType type = 0;
+
+    if (type == 0)
+	type = g_boxed_type_register_static
+	    ("GsfZipVDir",
+	     (GBoxedCopyFunc) gsf_vdir_copy,
+	     (GBoxedFreeFunc) gsf_vdir_destroy);
+
+    return type;
+}
+
 void
 gsf_vdir_add_child (GsfZipVDir *vdir, GsfZipVDir *child)
 {



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