最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

How to remove markdown files from treeview in Doxygen 1.9.1 - Stack Overflow

programmeradmin0浏览0评论

I am using Doxygen 1.9.1 to generate documentation for a code base. It works great generally, except for the top level documentation. I've written the top level docs using markdown, and every file shows up in the treeview whether I like it or not.

Here's my main.md file:

\mainpage

1. \subpage page1
  - \ref subpageA
2. \subpage page2

Current treeview:
|-Title page
|--Page 1
|--Page 2
|--file 1
|--subpage of page 1
.
|--final file

When I'd really like it to look like:
|-Title page
|--Page 1
|---subpage
|--Page 2

Can I explicitly set a tag in the individual markdown files that will exclude it from the tree? How do I include subpages where they belong in the tree? I've tried tagging them as subpages in main.md, which puts them at the same level as the full pages. I'd also be ok keeping them in the treeview, as long as they populate the tree under the page they're referenced in.

All of the pages are markdown format (this answer says you're stuck with them at the base level if they're markdown files. I'm ok changing to a different format, I just don't know what would work best (can I make them .dox files and do EXTENSION_MAPPING = dox=md?))

I know I can also use Doxygen grouping but I'm having trouble making that work as well (I tried \addtogroup at the top of each extra file I didn't want in the treeview, but that didn't work.)

If I use \ref pageName and add a \page pageName to the top of each file, it works, but still shows up at the base level of the treeview.

I am stuck using Doxygen 1.9.1 (I am not the admin on the machine where my code lives and builds).

Do I just need to ditch the idea of fixing the treeview on my version of Doxygen? Or is there any workaround?

More files, for your reference:
page1.md:

\page page1 This is Page 1

Page one has a [subpage](\ref subpageA)

page2.md:

\page page2 This is page 2

\section section1 One section of links to files
 - [link 1](file3.md)
 - [link 2](file4.md)

\section section2 A different section of links to fiels
 - [link 1 again](file3.md)
 - [link 3](file5.md)

subpageA.md:

\page subpageA This is a subpage

In this subpage, we reference some different files
 - [like this one](file1.md)
 - [and this one](file2.md)
发布评论

评论列表(0)

  1. 暂无评论