Doxygen
Developed under Linux, the comments in code are generally annotated in doxygen format, which is a good way to help us build our documentation.
For Doxygen's main syntax, there's a lot of instructions on the web, and there's a project: the Doxygen in GNOME Power Manager
Note Writing is very good, you can download down to see, and can learn from their actual development.
Here's what I'd like to say: How to extract the Open-source documentation from source code.
There are 3 tools you can install first:
1 Doxygen
2 Graphviz
3 HTMLHelp
1 Doxygen is a well-known code documentation tool.
Download Address: www.doxygen.org
Install it.
2 Graphviz
This tool is used with Doxygen, can extract functions, the call relationship between modules, very clear.
Download Address: http://www.graphviz.org/Download..php
Here are some diagrams extracted by Graphviz:
|
|
|
|
Cluster |
Crazy |
Datastruct |
Fsm |
|
|
|
|
Hello |
Profile |
Sdh |
Switch |
|
|
|
|
Unix |
World |
Twopi2 |
ER |
|
|
|
|
Fdpclust |
Process |
Softmaint |
Transparency |
3 HTMLHelp
This tool transforms the HTML file generated by Doxygen into a CHM file, which looks more convenient.
Download Address: http://www.softpedia.com/get/Authoring-tools/Help-e-book-creators/HTML-Help-Workshop.shtml
Install it.
4 We take the Gnome Power Manager as an example to see how to use these tools to provide our documentation capabilities.
SOURCE Download Address:
http://www.gnome.org/projects/gnome-power-manager/
Download the source code, after decompression, we take a look at if using the above 3 tools:
First with Doxygen: The generated Help document contains, call graph. Then use the HTMLHELP Workshop: the generated CHM file: and the individual invocation relationships, at a glance: from the generated code comments, GNOME Power Manager is very good for annotations, which can be used in our actual development. In addition, GNOME Power Manager is the best for gobject, and you can use it as a reference.