Difference between revisions of "Doxygen"
From GnuCash
(fix of several links; improve format) |
C.holtermann (talk | contribs) (Doxygen installed is necessary. Ninja is also possible.) |
||
Line 14: | Line 14: | ||
make doc | make doc | ||
</SyntaxHighlight> | </SyntaxHighlight> | ||
+ | or if building with ninja: | ||
+ | <SyntaxHighlight lang="sh"> | ||
+ | ninja doc | ||
+ | </SyntaxHighlight> | ||
+ | |||
+ | You need to have doxygen installed for this. Otherwise the target doc will not be available. | ||
+ | |||
This will populate <tt>${BUILDDIR}/libgnucash/doc</tt>. Problems will be logged there to <tt>doxygen.log</tt>. The HTML docs can be found in it's subdirectory <tt>html</tt>. | This will populate <tt>${BUILDDIR}/libgnucash/doc</tt>. Problems will be logged there to <tt>doxygen.log</tt>. The HTML docs can be found in it's subdirectory <tt>html</tt>. | ||
Revision as of 09:43, 20 June 2020
Doxygen is the central point for source documentation at this moment (January 2011).
It is a software which extracts (special) comments from sourcecode to produce source documentation.
- Nightlies
- This is done and put online on a regular basis at code.gnucash.org/docs/ for both branches :
- MAINT, the next minor bugfix and
- MASTER, the next major release.
Contents
Creating the Source Documentation
It can be run on your local copy of the sources by
make doc
or if building with ninja:
ninja doc
You need to have doxygen installed for this. Otherwise the target doc will not be available.
This will populate ${BUILDDIR}/libgnucash/doc. Problems will be logged there to doxygen.log. The HTML docs can be found in it's subdirectory html.
It's configuration gets created from ${SOURCEDIR}/libgnucash/doc/doxygen.cfg.in.
Doxygen Elements
- To mark a C style comment for Doxygen, it has to start with /** or /*!.
- Usually the explaining comment should be in front of a declaration. If the comment is behind a member declaration, the next symbol should be
<
, resulting in /**< or /*!<. - Doxygen keywords begin with
\
or@
. - To document global objects, you must document the file in which they are defined:
/*! \file */
- or
/** @file */
Improving the Source Documentation
A header file of a public API should have the following Doxygen section:/**
* @addtogroup <module>
* @{
* @file
* @brief <A brief description>
* @author Copyright (C) <year> <name> <email>
*/
Links
- GnuCash API Documentation
- MAINT
- MASTER
- Doxygen
- Website
- Repository