.. _graphviz_example: Graphviz Example ~~~~~~~~~~~~~~~~ There is a plugin for ``sphinx`` called ``sphinx.ext.graphviz`` which adds support for embedding ``graphviz`` graphs in your documents. One can achieve this by following these instructions: #. Make sure ``graphviz`` is properly installed on your machine/environment, for instance it can be installed via ``conda`` like this: .. code-block:: bash conda install -c conda-forge graphviz #. Make sure that this plugin would be recognized in your ``conf.py`` by adding it to the ``extentions`` list .. note:: In this project the ``conf.py`` is generated by ``cmake`` from the ``conf.py.in`` file and therefore this addition should be added to ``conf.py.in`` since it's the template file for the generated ``conf.py``. .. code-block:: python extentions = [ ... "sphinx.ext.graphviz", ... ] After those instructions you should be able to add the following directives in your ``.rst`` files .. code-block:: rst .. graphviz:: digraph foo { "bar" -> "baz"; } Here is how it looks: .. graphviz:: digraph foo { "bar" -> "baz"; }