Doxygen uses a configuration file to determine its settings, therefore it is paramount that this be created correctly. Each project needs its own configuration file. The most painless way to create the configuration file is with the command doxygen -g config-file. This creates a template configuration file that can be easily edited. The variable config-file is the name of the configuration file. If it is committed from the command it is simply called Doxyfile by default. Another useful option while creating the configuration file is the use of a minus sign (-) as the file name. This is useful for scripting as it will cause Doxygen to attempt to read the configuration file from standard input (stdin).
The configuration file consists of a number of variables and tags, similar to a simple Makefile. For example:
TAGNAME = VALUE1 VALUE2...
For the most part these can be left alone but should the need arise to edit them refer to the
configuration page of the Doxygen documentation website for an extensive explanation of all the tags available. There is also a GUI interface called
doxywizard. If this is the preferred method of editing then documentation for this function can be found on the
Doxywizard usage page of the Doxygen documentation website.
There are eight tags that are useful to become familiar with.
For small projects consisting mainly of C or C++ source and header files there is no need to change things. However, if the project is large and consists of a source directory or tree, then assign the root directory or directories to the INPUT tag.
File patterns (for example, *.cpp or *.h) can be added to this tag allowing only files that match one of the patterns to be parsed.
Setting this to yes will allow recursive parsing of a source tree.
These are used to further fine-tune the files that are parsed by adding file patterns to avoid. For example, to omit all test directories from a source tree, use EXCLUDE_PATTERNS = */test/*.
When this is set to yes, doxygen will pretend that everything in the source files is documented to give an idea of how a fully documented project would look. However, warnings regarding undocumented members will not be generated in this mode; set it back to no when finished to correct this.
By setting the SOURCE_BROWSER tag to yes doxygen will generate a cross-reference to analyze a piece of software's definition in its source files with the documentation existing about it. These sources can also be included in the documentation by setting INLINE_SOURCES to yes.