The easy Weblog and Wiki Software
[ start | index | login ]
start > SnipGraph > Tree Example

Tree Example

Created by leo. Last edited by leo, one year and 319 days ago. Viewed 11,738 times. #29
[diff] [history] [edit] [rdf]
labels
Category:snipsnap-documentation
attachments

Description

The simplest renderer for graph is a tree renderer. You describe the tree using nested round braces. The content for each node is the text found right after the first brace '('. Additionally each node can have properties that are declared using brackets with special keywords. The properties can change how the node is displayed, i.e. background color.

Syntax

The graph macro argument for this syntax is one of:

{graph:horizontal}
{graph:vertical}
{graph:mindmap}

Addionation parameters:

{graph:type|width|ismap}
{graph:handler=type|size=width|ismap=true}

You need the second if you want to leave out size!

(ROOT (NODE1 (NNODE2 [PROPERTY] [PROPERTY]))

PropertyDescription
[TEXT TEXT]Creates a subtitle for the nodes text box
[:color:«color»]Changes the text color to the value of «color», which may be an RGB value #rrggbb or a color name such as orange or black
[:background:«color»]Changes the box background to the value of «color», which may be an RGB value #rrggbb or a color name such as orange or black
[:url:http://host.com/]Creates a link if this graph is rendered using a picture map.
[:status:«current status»]if done the node is crossed out.

Example

{graph:handler=vertical|ismap=true}
(FIRST[Hauptfeld][:color:#DD5587][:background:#554488]
	(Second1 lang[name name][:color:#AA99FF][:background:orange][:url:>>http://www.first.fraunhofer.de]
			(Third2[name name][:color:blue]
				(Fourth1)
				(Fourth2[name name])
			)
			(Third5 [name name][:color:blue])
			(Third6 [name name][:color:blue])

) (Second2[name name][:background:orange] (Third3[name name][:color:blue] (Fourth5 [name name]) (Fourth6) ) (Third4 [name name][:color:blue][:status:done]) ) (Second3[name name][:background:orange] (Third9 [name name][:color:blue]) (Third10 [name name][:color:blue]) ) (Second4[name name][:background:orange] (Third7 [name name][:color:blue]) (Third8 [name name][:color:blue] (Fourth7 [name name][:url:>>http://www.hund.de]) (Fourth8) ) ) ) {graph}

Rendering

Select the way you want the source rendered: [ MindMap | Horizontal | Vertical ]

graph: null
7 comments (by GaryPaulson, cris, caseyd, Hoppe, paularmstrong, guest) | post comment

What is SnipSnap?
SnipSnap is a free and easy to install weblog and wiki tool written in Java.

SnipSnap download
Current version: 1.0b3-uttoxeter
Try our >>Web Start Demo!

Resources

5567 Users and 13712 Snips. Installed 5 years and 363 days ago

Logged in Users: (2)
… and 20 Guests.

snipsnap-changed for older changes.

< July 2008 >
SunMonTueWedThuFriSat
12345
6789101112
13141516171819
20212223242526
2728293031

snipsnap
Listed on BlogShares
XHTML 1.0 validated
CSS validated
RSS 2.0 validated
RSS Feed

pico-powered

Powered by SnipSnap 1.0b3-uttoxeter
YourKit >>Java Profiler

Fraunhofer FIRST

snipsnap.org | Copyright 2000-2006 Fraunhofer FIRST