I am trying document my code using Doxygen. I want the resulting HTML to organize the tree view acording to a SW architecture for simple and fast understanding of the project. I have a project organized like this:
│ project_description.md
├───application
│ │ application.md
│ ├───app1
│ │ app1.c
│ │ app1.h
│ │ app1.md
│ └───app2
│ app2.c
│ app2.h
│ app2.md
└───ecu_abstraction
│ ecu_abstraction.md
├───component1
│ custom_timer.c
│ custom_timer.h
│ custom_timer.md
└───component2
custom_component2.c
custom_component2.h
custom_component2.md
The issue I am having is that the tree view auto-generated by doxygen is flat. All elements have the same level. Current result is:
My objective is to have something like this:
I have made some attempts with grouping and sections but all of them seems to merge the documentation files. Any idea if this can be implemented with Doxygen?
I know I can achieve a similar result by disabling the autogenerated tree view and using @ref but creating a manual table of contex is not very flexible nor future proof.
Attempts with addtogroup functionality:
- Adding the line
@addtogroup applicationin the markdown files concatenates them in the module "application". - Adding to a group specific functions or the module declaration to a group adds those functions to the same generic module description.
This means that if I add all my applications to the application layer all of those are concatenated and one single page is created.
Sample markdown file:
@addtogroup application
# App1
bla bla
Sample C file addition to a group
/**
* @addtogroup application
* @{
* @file app2.c
*
* @brief Custom simpe timer implementation that allows for simple tick, reste...
* @}
*/



It's a little bit late answer, the OP may have solved the matter who knows. Anyway, the implementation according to the OP's requirement should be like the following steps. Assume that we have the source files as *.h and *.c pair:
First we would implement a application doc file:
app_doc.dox
Next we would document all indiviual files. But we create new groups using the defgroup command within the related header files only. Right after creating the groups, we make them subgroups using the ingroup command. This will nest the groups and create a hierarchic documentation within the tree view as a result. Note that we also add the *.c file to their related groups. However this may not be necessary unless you have more documentations that belong the same group in the *.c files.
app1.h
app1.c
app2.h
app2.c
custom_timer.h
custom_timer.c
custom_component.h
custom_component.c
The Doxygen version I used to generate documentation is
1.9.6. I have generated the documentation using Doxywizard in Linux platform. Finally an image that shows the result.Unfortunately I cannot add the specific doxygen config file since it is large and there is a body character limit in answers. But no worries I uploaded it in a cloud storage so that you can download and view.
Edit
Thanks to @albert for the reminder so I also leave the doxygen configuration as condensed view form in case of the original Doxyfile is not available from the cloud drive.