In general, gtkmm-style projects use Doxygen, which reads specially formatted C++ comments and generates HTML documentation. You may write these doxygen comments directly in the header files.
You might wish to reuse documentation that exists for the C library that
you are wrapping. GTK-style C libraries typically use gtk-doc and therefore
have source code comments formatted for gtk-doc and some extra documentation
in .sgml and .xml files. The docextract_to_xml.py script, from glibmm's
tools/defs_gen
directory, can read these files and
generate an .xml file that gmmproc can use to generate
doxygen comments. gmmproc will even try to transform the
documentation to make it more appropriate for a C++ API.
For instance,
./docextract_to_xml.py -s ~/checkout/gnome/gtk+/gtk/ > gtk_docs.xml
Because this automatic transformation is not always appropriate, you might
want to provide hand-written text for a particular method. You can do this
by copying the XML node for the function from your
something_docs.xml
file to the
something_docs_override.xml
file and changing the
contents.
If you copied the skeleton source tree in mm-common and substituted the
placeholder text, then you will already have suitable Makefile.am
and Doxyfile.in
files. With the mm-common build setup, the list
of Doxygen input files is not defined in the Doxygen configuration file, but passed
along from make to the standard input of doxygen.
The input file list is defined by the doc_input
variable in the
Makefile.am
file.