[gimp] libgimpthumb: move docs from template files to inline comments



commit 58dbc8d8390e1c1773fdfad3e3e794e837140643
Author: Michael Natterer <mitch gimp org>
Date:   Fri Jul 2 15:53:20 2010 +0200

    libgimpthumb: move docs from template files to inline comments

 devel-docs/libgimpthumb/.gitignore                |    1 +
 devel-docs/libgimpthumb/tmpl/.gitignore           |    2 -
 devel-docs/libgimpthumb/tmpl/gimpthumb-enums.sgml |   54 -----
 devel-docs/libgimpthumb/tmpl/gimpthumb-error.sgml |   44 -----
 devel-docs/libgimpthumb/tmpl/gimpthumb-utils.sgml |  127 ------------
 devel-docs/libgimpthumb/tmpl/gimpthumbnail.sgml   |  216 ---------------------
 libgimpthumb/gimpthumb-enums.h                    |   42 ++++
 libgimpthumb/gimpthumb-error.c                    |    9 +
 libgimpthumb/gimpthumb-error.h                    |   20 ++-
 libgimpthumb/gimpthumb-utils.c                    |    9 +
 libgimpthumb/gimpthumbnail.c                      |    9 +
 libgimpthumb/gimpthumbnail.h                      |    1 +
 12 files changed, 88 insertions(+), 446 deletions(-)
---
diff --git a/devel-docs/libgimpthumb/.gitignore b/devel-docs/libgimpthumb/.gitignore
index af1e625..94fa608 100644
--- a/devel-docs/libgimpthumb/.gitignore
+++ b/devel-docs/libgimpthumb/.gitignore
@@ -12,6 +12,7 @@
 /libgimpthumb-undeclared.txt
 /libgimpthumb-undocumented.txt
 /html
+/tmpl
 /xml
 /version
 /.libs
diff --git a/libgimpthumb/gimpthumb-enums.h b/libgimpthumb/gimpthumb-enums.h
index 6b11bdc..b86b8a6 100644
--- a/libgimpthumb/gimpthumb-enums.h
+++ b/libgimpthumb/gimpthumb-enums.h
@@ -28,6 +28,24 @@
 G_BEGIN_DECLS
 
 
+/**
+ * SECTION: gimpthumb-enums
+ * @title: GimpThumb-enums
+ * @short_description: Enumerations used by libgimpthumb
+ *
+ * Enumerations used by libgimpthumb
+ **/
+
+
+/**
+ * GimpThumbFileType:
+ * @GIMP_THUMB_FILE_TYPE_NONE:    file does not exist
+ * @GIMP_THUMB_FILE_TYPE_REGULAR: a regular file
+ * @GIMP_THUMB_FILE_TYPE_FOLDER:  a directory
+ * @GIMP_THUMB_FILE_TYPE_SPECIAL: a special file (device node, fifo, socket, ...)
+ *
+ * File types as returned by gimp_thumb_file_test().
+ **/
 #define GIMP_TYPE_THUMB_FILE_TYPE (gimp_thumb_file_type_get_type ())
 
 GType gimp_thumb_file_type_get_type (void) G_GNUC_CONST;
@@ -41,6 +59,16 @@ typedef enum
 } GimpThumbFileType;
 
 
+/**
+ * GimpThumbSize:
+ * @GIMP_THUMB_SIZE_FAIL:   special size used to indicate a thumbnail
+ *                          creation failure
+ * @GIMP_THUMB_SIZE_NORMAL: normal thumbnail size (128 pixels)
+ * @GIMP_THUMB_SIZE_LARGE:  large thumbnail size (256 pixels)
+ *
+ * Possible thumbnail sizes as defined by the Thumbnail Managaging
+ * Standard.
+ **/
 #define GIMP_TYPE_THUMB_SIZE (gimp_thumb_size_get_type ())
 
 GType gimp_thumb_size_get_type (void) G_GNUC_CONST;
@@ -53,6 +81,20 @@ typedef enum
 } GimpThumbSize;
 
 
+/**
+ * GimpThumbState:
+ * @GIMP_THUMB_STATE_UNKNOWN:   nothing is known about the file/thumbnail
+ * @GIMP_THUMB_STATE_REMOTE:    the file is on a remote file system
+ * @GIMP_THUMB_STATE_FOLDER:
+ * @GIMP_THUMB_STATE_SPECIAL:
+ * @GIMP_THUMB_STATE_NOT_FOUND: the file/thumbnail doesn't exist
+ * @GIMP_THUMB_STATE_EXISTS:    the file/thumbnail exists
+ * @GIMP_THUMB_STATE_OLD:       the thumbnail may be outdated
+ * @GIMP_THUMB_STATE_FAILED:    the thumbnail couldn't be created
+ * @GIMP_THUMB_STATE_OK:        the thumbnail exists and matches the image
+ *
+ * Possible image and thumbnail file states used by libgimpthumb.
+ **/
 #define GIMP_TYPE_THUMB_STATE (gimp_thumb_state_get_type ())
 
 GType gimp_thumb_state_get_type (void) G_GNUC_CONST;
diff --git a/libgimpthumb/gimpthumb-error.c b/libgimpthumb/gimpthumb-error.c
index 5970b85..e14f4fe 100644
--- a/libgimpthumb/gimpthumb-error.c
+++ b/libgimpthumb/gimpthumb-error.c
@@ -30,6 +30,15 @@
 
 
 /**
+ * SECTION: gimpthumb-error
+ * @title: GimpThumb-error
+ * @short_description: Error codes used by libgimpthumb
+ *
+ * Error codes used by libgimpthumb
+ **/
+
+
+/**
  * gimp_thumb_error_quark:
  *
  * This function is never called directly. Use GIMP_THUMB_ERROR() instead.
diff --git a/libgimpthumb/gimpthumb-error.h b/libgimpthumb/gimpthumb-error.h
index 277908f..69e718e 100644
--- a/libgimpthumb/gimpthumb-error.h
+++ b/libgimpthumb/gimpthumb-error.h
@@ -28,14 +28,28 @@
 G_BEGIN_DECLS
 
 
+/**
+ * GimpThumbError:
+ * @GIMP_THUMB_ERROR_OPEN:         there was a problem opening the file
+ * @GIMP_THUMB_ERROR_OPEN_ENOENT:  the file doesn't exist
+ * @GIMP_THUMB_ERROR_MKDIR:        there was a problem creating a directory
+ *
+ * These are the possible error codes used when a #GError is set by
+ * libgimpthumb.
+ **/
 typedef enum
 {
-  GIMP_THUMB_ERROR_OPEN,         /*  open failed                            */
-  GIMP_THUMB_ERROR_OPEN_ENOENT,  /*  file does not exist                    */
-  GIMP_THUMB_ERROR_MKDIR         /*  mkdir failed                           */
+  GIMP_THUMB_ERROR_OPEN,
+  GIMP_THUMB_ERROR_OPEN_ENOENT,
+  GIMP_THUMB_ERROR_MKDIR
 } GimpThumbError;
 
 
+/**
+ * GIMP_THUMB_ERROR:
+ *
+ * Identifier for the libgimpthumb error domain.
+ **/
 #define GIMP_THUMB_ERROR (gimp_thumb_error_quark ())
 
 GQuark  gimp_thumb_error_quark (void) G_GNUC_CONST;
diff --git a/libgimpthumb/gimpthumb-utils.c b/libgimpthumb/gimpthumb-utils.c
index 4c72cb4..15b946c 100644
--- a/libgimpthumb/gimpthumb-utils.c
+++ b/libgimpthumb/gimpthumb-utils.c
@@ -46,6 +46,15 @@
 #include "libgimp/libgimp-intl.h"
 
 
+/**
+ * SECTION: gimpthumb-utils
+ * @title: GimpThumb-utils
+ * @short_description: Utility functions provided and used by libgimpthumb
+ *
+ * Utility functions provided and used by libgimpthumb
+ **/
+
+
 static gint           gimp_thumb_size       (GimpThumbSize  size);
 static gchar        * gimp_thumb_png_lookup (const gchar   *name,
                                              const gchar   *basedir,
diff --git a/libgimpthumb/gimpthumbnail.c b/libgimpthumb/gimpthumbnail.c
index 45e441d..c64b3a0 100644
--- a/libgimpthumb/gimpthumbnail.c
+++ b/libgimpthumb/gimpthumbnail.c
@@ -51,6 +51,15 @@
 #include "libgimp/libgimp-intl.h"
 
 
+/**
+ * SECTION: gimpthumbnail
+ * @title: GimpThumbnail
+ * @short_description: The GimpThumbnail object
+ *
+ * The GimpThumbnail object
+ **/
+
+
 /*  #define GIMP_THUMB_DEBUG  */
 
 
diff --git a/libgimpthumb/gimpthumbnail.h b/libgimpthumb/gimpthumbnail.h
index 2c8ea38..e8eeb7d 100644
--- a/libgimpthumb/gimpthumbnail.h
+++ b/libgimpthumb/gimpthumbnail.h
@@ -42,6 +42,7 @@ struct _GimpThumbnail
 {
   GObject         parent_instance;
 
+  /*< private >*/
   GimpThumbState  image_state;
   gchar          *image_uri;
   gchar          *image_filename;



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