Include images in doxygen documentation
authorColin Clark <colin.clark@cclark.uk>
Sun, 20 Aug 2023 12:47:51 +0000 (13:47 +0100)
committerColin Clark <colin.clark@cclark.uk>
Sun, 20 Aug 2023 12:47:51 +0000 (13:47 +0100)
Include two sample images of dialog layouts.

doc/image-style.css [new file with mode: 0644]
doc/images/file_util_file_dlg.png [new file with mode: 0644]
doc/images/file_util_gen_dlg.png [new file with mode: 0644]
doxygen.conf
src/utilops.cc

diff --git a/doc/image-style.css b/doc/image-style.css
new file mode 100644 (file)
index 0000000..3623dad
--- /dev/null
@@ -0,0 +1,4 @@
+.image
+{
+   text-align: left;
+}
diff --git a/doc/images/file_util_file_dlg.png b/doc/images/file_util_file_dlg.png
new file mode 100644 (file)
index 0000000..26f511a
Binary files /dev/null and b/doc/images/file_util_file_dlg.png differ
diff --git a/doc/images/file_util_gen_dlg.png b/doc/images/file_util_gen_dlg.png
new file mode 100644 (file)
index 0000000..58aa857
Binary files /dev/null and b/doc/images/file_util_gen_dlg.png differ
index f869459..38b622e 100644 (file)
@@ -1010,7 +1010,7 @@ EXAMPLE_RECURSIVE      = NO
 # that contain images that are to be included in the documentation (see the
 # \image command).
 
-IMAGE_PATH             =
+IMAGE_PATH             = $(SRCDIR)/doc/images
 
 # The INPUT_FILTER tag can be used to specify a program that doxygen should
 # invoke to filter for each input file. Doxygen will invoke the filter program
@@ -1290,7 +1290,7 @@ HTML_STYLESHEET        =
 # list). For an example see the documentation.
 # This tag requires that the tag GENERATE_HTML is set to YES.
 
-HTML_EXTRA_STYLESHEET  =
+HTML_EXTRA_STYLESHEET  =  ./doc/image-style.css
 
 # The HTML_EXTRA_FILES tag can be used to specify one or more extra images or
 # other source files which should be copied to the HTML output directory. Note
index d2851ed..2a63130 100644 (file)
@@ -165,6 +165,18 @@ static void generic_dialog_add_image(GenericDialog *gd, GtkWidget *box,
  *--------------------------------------------------------------------------
  */
 
+/**
+ * @brief
+ * @param title
+ * @param role
+ * @param parent
+ * @param auto_close
+ * @param cancel_cb
+ * @param data
+ * @returns
+ *
+ * \image html file_util_gen_dlg.png "Typical implementation" width=200
+ */
 GenericDialog *file_util_gen_dlg(const gchar *title,
                                 const gchar *role,
                                 GtkWidget *parent, gboolean auto_close,
@@ -181,6 +193,17 @@ GenericDialog *file_util_gen_dlg(const gchar *title,
        return gd;
 }
 
+/**
+ * @brief
+ * @param title
+ * @param role
+ * @param parent
+ * @param cancel_cb
+ * @param data
+ * @returns
+ *
+ * \image html file_util_file_dlg.png "Typical implementation including optional filter, buttons and path widgets" width=300
+ */
 FileDialog *file_util_file_dlg(const gchar *title,
                               const gchar *role,
                               GtkWidget *parent,