Skip to main content

Graphviz extension for docutils

Project description

===============================
Graphviz extension for Docutils
===============================

A Docutils extension that replaces inline Graphviz definitins with inline SVGs or PNGs!

refer: https://github.com/sprin/markdown-inline-graphviz

Install `Graphviz <https://www.graphviz.org/>`_ first! The command "dot" should be in system PATH.


register::

import docutils_graphviz
from docutils.parsers.rst import directives

directives.register_directive('dot', docutils_graphviz.Graphviz)

example:

.. dot:: svg
:widht: 100%
:height: 100%
:alt: image.svg

digraph G {
node[fontname="simsun"]
edge[fontname="simsun"]

rankdir=LR
Earth [peripheries=2]
Mars
Earth -> Mars
}

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for python-docutils-graphviz, version 1.0.3
Filename, size File type Python version Upload date Hashes
Filename, size python-docutils-graphviz-1.0.3.tar.gz (2.3 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page