|
Creation of new graphsCreate a new xml file in your favorite text editor and copy the following code into the empty file: <?xml version="1.0"?> <!DOCTYPE GraphXML SYSTEM "GraphXML.dtd"> <GraphXML> <graph id="My First Graph"> <!-- Here come your nodes --> <!-- Here come the edges --> </graph> </GraphXML> Now enter your nodes. A node has a unique name, which is used to reference this node, and a label. The label is shown in the applet. If no label is given, the name of the node is shown as a label. The node element looks like : <node name="node1"> <label>Label of first node</label> </node> You may enter as many nodes as you like, just make sure that the name is always unique. Now enter the edges, i.e. the connection between the different nodes. An edge has a source and a target, which are the unique names of the nodes : <edge source="node1" target="node2" /> That's all. If you want to know more about the GraphXML format, how to colour nodes and edges etc., see here. |