Description

This parser allows you to embed Graphviz graph visualizations in your wiki pages.

Download

Version

File

Notes

0.2.3

GraphvizParser-0.2.3.tar.bz2

Fixed graph attachment detection where no dimension attributes are specified

0.2.2

GraphvizParser-0.2.2.tar.bz2

0.2.1 with Moin 1.9 request API fix

0.2.1

GraphvizParser-0.2.1.tar.bz2

0.2 with encoding and subprocess fixes

0.2

GraphvizParser-0.2.tar.bz2

Revised version with SVG support

0.1

graphviz_0.1.py

initial release

Installation

/!\ Be sure to read the list of known bugs found in graphviz.py (or the known issues in README.txt) prior to installation.

Make sure Graphviz is installed and functional.

License/Copyright

Released under the terms of the GNU GPL.

Copyright (C) 2008 Wayne Tucker.

Copyright (C) 2011, 2012 Paul Boddie <paul AT boddie DOT org DOT uk>

Copyright (C) 2012 Frederick Capovilla (Libéo) <fcapovilla AT SPAMFREE live DOT ca>

Discussion

I've made a patch which adds support for SVG, since modern browsers are capable of embedding such images without plugins. Unfortunately, the sizing of embedded images isn't right first time, but the browser usually learns the size fairly quickly. This could be overcome by letting the user specify the dimensions of the image (maybe just the width or height) using the comment syntax. -- PaulBoddie 2011-09-19 22:06:08

Encoding and Subprocess Problems

(!) Fix incorporated into the 0.2.1 release. The discussion below is for future reference. -- PaulBoddie 2012-03-06 23:50:01

I encountered some character encoding problems when trying to use accented characters in labels and hrefs. Here is a patch that corrects the character encoding problem by always converting the data to utf-8. This patch also uses subprocess.communicate() instead of reading and writing directly to stderr and stdin to avoid random "Broken pipe" errors. -- FrederickCapovilla 2012-03-05 18:26:00

request.flush() doesn't work in 1.9

Your plugin didn't work for me until I commented out line 80 of graphviz.py

request.flush() # to identify error text

Using cmapx for image maps

Can you provide instructions on how to use cmapx in your plugin? By reading the source, I gathered that you need to set up something like this.

{{{#!graphviz
//format="png"
//cmapx="true"
digraph DevProcess {
  URL="http://www.gmail.com";
  "Bug Fixed?" [URL="http://www.google.com"];
}
}}}

But beyond that, I'm a little stumped.

MoinMoin: ParserMarket/graphviz (last edited 2012-04-19 01:17:06 by BrettWeir)