1

I'm new to Doxygen and not an expert with HTML and I am trying to change the header and/or footer on my Doxygen outputted page.

I tried editing the main.html and tree.html, but whenever I run Doxygen (command line - doxygen Doxyfile) it refreshes and ignores and deletes all of the changes I made.

I'm just trying to personalize the background, add a company logo, and anything else. How do I do this?

Miyah Boyd
  • 11
  • 3
  • Have a look at the documentation the chapter "Customizing the output" (http://www.doxygen.nl/manual/customize.html) and the paragraph "Header, Footer, and Stylesheet changes" (http://www.doxygen.nl/manual/customize.html#minor_tweaks_header_css). – albert Jul 30 '19 at 18:35

1 Answers1

0

You can accomplish what you are looking for by using the HTML_HEADER and HTML_FOOTER tags.

You will want to create your template header and footer files. You can do that by executing the following command:

doxygen -w html header.html footer.html customdoxygen.css

(check the Doxygen Config documentation for available parameters you can include in your files).

Once you have your template files saved where you want, and customized (I would recommend one level up from your source, or if you have a generic content folder), add them into your config file.

e.g.

PROJECT_NAME = "My Code Hack"
...
HTML_HEADER = /build/librarys/doxy/parts/header.html
HTML_FOOTER = /build/librarys/doxy/parts/footer.html

That should give you what you are looking for.

Roy Folkker
  • 407
  • 3
  • 8
  • So, from just fiddling around with the code on the main.html it works but my problem is when I run Doxygen to update other information all of the work I did in the main.html is refreshed/erased. Why is that? I'm unsure what having a header and footer html does and what should go into them. – Miyah Boyd Jul 30 '19 at 20:28
  • You will want to export them and look at their contents to truly understand what they do; tweak them and see how it changes. The header and footer files allow you to make persistent changes to the output that are not part of the document generation. I am not sure what more to tell you on that. But, run the export (-w) and look at the contents of the files. – Roy Folkker Jul 30 '19 at 20:50