Skip to main content

Ralsina.Me — Roberto Alsina's website

Lunchtime Nikola Feature: graphviz

Since we are in the process of adding a plug­in re­po for Niko­la, I want­ed to add a sim­ple plug­in there so that we can show how it work­s.

So here it is. You use this:

.. graphviz::

   digraph foo {
       "Idea" -> "tap tap tap" -> "Code";
   }

And you get (as­sum­ing graphviz is in­stalled, and this plug­in is in­stalled, etc.) this:

b'\n\n\n\n\n\nfoo\n\n\n\nIdea\n\nIdea\n\n\n\ntap tap tap\n\ntap tap tap\n\n\n\nIdea->tap tap tap\n\n\n\n\n\nCode\n\nCode\n\n\n\ntap tap tap->Code\n\n\n\n\n\n'

It's still very rudi­men­ta­ry, but it aims to be com­pat­i­ble with Sphinx's im­ple­men­ta­tion even though the de­tails of how it's done vary great­ly.

ddevine / 2013-09-28 00:18:

This is awesome. Do want!

Roberto Alsina / 2013-09-28 01:43:

Go right ahead :-)

The version at http://plugins.getnikola.com has a bunch of improvements over the one I used here.

ivanelson / 2014-01-28 14:48:

I really like your posts. However, I never thought to click on ads. In fact I never realized that they exist. : (

But please do not stop writing about PyQt and Pythoh.

Your articles are great! Will stand for all humanity. :)


Contents © 2000-2023 Roberto Alsina