1 Basic Usage
2 -----------
3
4 Embed a visualization of a graph in a wiki page:
5
6 {{{#!graphviz
7 digraph G {
8 A -> B;
9 };
10 }}}
11
12 Advanced Usage
13 --------------
14
15 This parser will check the first lines of the Graphviz data for C++ style
16 comments instructing it to use a different filter (dot, neato, twopi, circo,
17 or fdp - see http://graphviz.org/ for more info), use a different format for
18 the output (see the FORMATS list in the Parser class), or to generate and pass
19 a client-side image map.
20
21 Options:
22
23 filter - the filter to use (see Parser.FILTERS)
24 format - the output format (see Parser.FORMATS)
25 cmapx - the map name to use for the client-side image map; this must match
26 the graph name in the graph definition and shouldn't conflict with
27 any other graphs that are used on the same page; for SVG images, the
28 cmapx option is superfluous since SVG supports linking natively and
29 Graphviz converts "href" attributes appropriately
30
31 Embed a visualization of a graph in a wiki page, using the dot filter and
32 providing a client-side image map (the filter=dot and format=png options are
33 redundant since those are the defaults for this parser):
34
35 {{{#!graphviz
36 //filter=dot
37 //format=png
38 //cmapx=DocumentationMap
39 digraph DocumentationMap {
40 FrontPage [href="FrontPage", root=true];
41 HelpOnEditing [href="HelpOnEditing"];
42 SyntaxReference [href="SyntaxReference"];
43 WikiSandBox [href="WikiSandBox", color="grey"];
44 MoinMoin [href="http://moinmo.in"];
45 FrontPage -> WikiSandBox;
46 FrontPage -> MoinMoin;
47 WikiSandBox -> HelpOnEditing;
48 WikiSandBox -> SyntaxReference;
49 SyntaxReference -> FrontPage;
50 };
51 }}}
52
53 Known Bugs
54 ----------
55
56 - Hasn't been thoroughly checked for potential methods of injecting
57 arbitrary HTML into the output.
58 - Only compatible with HTML rendering
59 - May not use all of the MoinMoin interfaces properly - this is a
60 quick hack based on looking at an example and digging through the
61 MoinMoin source. The MoinMoin development docs haven't been
62 consulted (yet).
63 - Comments must start at the beginning of the graphviz block, and at the
64 beginning of their respective lines. They must also not contain
65 any extra whitespace surrounding the = sign.