summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorzweistein <zweistein@web>2020-03-07 14:01:14 +0000
committerIkiWiki <ikiwiki.info>2020-03-07 14:01:14 +0000
commitc24f6cbf76237a312ab0e1af53b313f2b8c15e09 (patch)
treebd0bd7d15eeca51b5aeaf517220d6e062815d46f
parent0081f3ab21b02874b0cae8e9e31fa6a9ed32f36a (diff)
aktiv?
-rw-r--r--ikiwiki/directive/graph.mdwn38
1 files changed, 38 insertions, 0 deletions
diff --git a/ikiwiki/directive/graph.mdwn b/ikiwiki/directive/graph.mdwn
new file mode 100644
index 00000000..4f02a9c4
--- /dev/null
+++ b/ikiwiki/directive/graph.mdwn
@@ -0,0 +1,38 @@
+[[!if test="enabled(graph)"
+ then="In diesem Wiki ist die Direktive: graph **aktiviert**."
+ else="In diesem Wiki ist die Direktive: graph **nicht aktiv**; falls dies gewünscht wird, den Admin benachrichtigen."]]
+
+---
+The `graph` directive is supplied by the [[!iki plugins/graphviz desc=graphviz]] plugin.
+
+This directive allows embedding [graphviz](http://www.graphviz.org/)
+graphs in a page. Example usage:
+
+ \[[!graph src="a -> b -> c; a -> c;"]]
+
+Nodes on the graph can link to external urls using regular graphviz syntax,
+and a clickable imagemap will be created. As a special extension for
+ikiwiki, [[WikiLinks|ikiwiki/wikilink]] can also be used. For example:
+
+ \[[!graph src="""
+ google [ href="http://google.com/" ]
+ sandbox [ href=\[[SandBox]] ]
+ help [ href=\[[ikiwiki/formatting]] ]
+ newpage [ href=\[[NewPage]] ]
+
+ google -> sandbox -> help -> newpage -> help -> google;
+ """]]
+
+The `graph` directive supports the following parameters:
+
+- `src` - The graphviz source to render.
+* `file` - A file in the wiki containing the graphviz source.
+- `type` - The type of graph to render: `graph` or `digraph`. Defaults to
+ `digraph`.
+- `prog` - The graphviz program to render with: `dot`, `neato`, `fdp`, `twopi`,
+ or `circo`. Defaults to `dot`.
+- `height`, `width` - Limit the size of the graph to a given height and width,
+ in inches. You must specify both to limit the size; otherwise, graphviz will
+ choose a size, without any limit.
+
+[[!meta robots="noindex, follow"]]