Breathe

Sphinx plugin providing beautifully integrated Doxygen output for C++ documentation in Sphinx.

cpp

About this Extension

Bridges Doxygen and Sphinx to combine C++ API documentation with user guides. Takes Doxygen’s excellent code parsing and presents it through Sphinx’s superior documentation system.

The workflow

  1. Doxygen parses your C++ source code and generates XML output
  2. Breathe reads that XML and creates Sphinx directives
  3. Sphinx renders everything together with your user documentation

This gives you the best of both worlds: Doxygen’s deep C++ understanding with Sphinx’s powerful documentation features.

What you can document

  • C++ classes, functions, enums, and variables
  • Function parameters and return values
  • Code examples and usage snippets
  • Cross-references between API and user guides
  • Inheritance diagrams and call graphs

Basic usage

.. doxygenclass:: MyClass
   :members:

.. doxygenfunction:: myFunction

.. doxygenstruct:: MyStruct
   :members:

Configuration

# conf.py
extensions = ['breathe']

# Point to Doxygen XML output
breathe_projects = {"myproject": "path/to/doxygen/xml/"}
breathe_default_project = "myproject"

# Optional: customize output
breathe_default_members = ('members', 'undoc-members')

Typical project structure

docs/
├── conf.py
├── index.rst
├── api/           # Generated API docs
└── doxygen_xml/   # Doxygen XML output

src/
└── *.cpp, *.h     # Your C++ code

Essential for C++ projects where you want comprehensive API documentation integrated with user guides, tutorials, and examples.

Author

Michael Jones

License

BSD License

Try it out!

We have not been able to validate your subscription.
You have been subscribed to SphinxThemes.com

We've got more coming...

Join the community and get notified every time we list a new Sphinx theme or extension.