A Bootstrap theme for Doxygen

At work, I started a C++/Cx repository in Visual Studio Online. I needed an easy way for consumers to read about the public APIs.

Doxygen turns out to be the de facto solution for this. It was super easy to hook up, I could document both in code and in separate files and I could document in markdown! I’ve found markdown to be the absolutely quickest way to write well structured comments. C# style Document XML is great, but not if you have to type it by hand. I might be swayed back to DocXML if Intellisense supported it for C++ and I could get a good comment generator going.

In any case, the website Doxygen creates is wonderful, but ugly:

Screenshot before

Luckily I found doxygen-bootstrapped which applies the goodness of Bootstrap. The original repo was a bit sparse on documentation, but I managed to figure things out and contributed an example site to get your project up and going quickly.

Screenshot after

Very pleased with the result. It’s even fairly responsive to screen width changes!

Side note

For anybody else needing to document C++ projects, you might have noticed that VS has a compiler option to generate DocXML. You could plug the XML output into Sandcastle and get a very nice looking site. The problem is that the DocXML compiler for C++ treats links in comments like code. What you’re linking to must be forward declared! This is incredibly impractical for comments where you want to link between different classes in your code base. Doxygen does not have this restriction.