ZVON > Graphotron > Graphotron Reference
| >> graphotron << | daVinci | vcg | dot | tutorial | download | about |

Namespace http://zvon.org/graphotron
Element edge
Description The edge element draws edges from nodes selected by match attribute to nodes selected by select attribute. Only nodes which have been assigned by vertex elements are used. If two vertices are connectd by several edge elements, all edges are drawn.
Attributes match [ required ]
The attribute selects starting edges. The match is equivalent to the match attribute of xsl:template in XSLT Recommendation.

select [ required ]
The attribute selects edge targets. If the select XPath is relative, than the selection by match attribute furnishes the base address. It is equivalent to the select attribute of xsl:apply-templates in XSLT Recommendation.
Children any:edge-property
Parents graphotron

XML Source

<source>
     <AAA/>
     <BBB/>
     <CCC/>
     <DDD/>
</source>
Graphotron Source

<graphotron version="1.0" xmlns="http://zvon.org/graphotron" xmlns:dot="http://zvon.org/graphotron/dot" >
     <vertex match="/*/*">
          <name select="name()"/>
     </vertex>
     <edge match="//*" select="/*/*[1]"/>
     <edge match="//*" select="following::*">
          <dot:color>blue</dot:color>
     </edge>
     <edge match="//*[3]" select="following::*">
          <dot:color>red</dot:color>
     </edge>
</graphotron>

Display
Graph screenshot