>[color=blue]
> <box caption="131"/>
> <box caption="133">
> <box caption="147"/>
> <box caption="159"/>
> </box>
> <box caption="135">
> <box caption="132">
> <box caption="142"/>
> <box caption="146"/>
> <box caption="192"/>
> </box>
> <box caption="143">
> <box caption="145"/>
> </box>
> <box caption="144"/>
> </box>[/color]
Applying the following stylesheet on the output above, would display structured SVG.
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns="http://www.w3.org/2000/svg"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:a3="http://ns.adobe.com/AdobeSVGViewerExtensions/3.0/"[color=blue]
>[/color]
<xsl:output method="xml" version="1.0" encoding="UTF-8"
indent="yes"/>
<xsl:key name="kOrga" match="/Orga/OrgaBox" use="@BelongsTo"/>
<xsl:template match="/">
<svg contentScriptType="text/ecmascript" width="500" height="500"
viewBox="0 0 10000 30000" a3:scriptImplementation="Adobe"
zoomAndPan="magnify" contentStyleType="text/css" id="PinFunction"
preserveAspectRatio="xMidYMid meet">
<defs>
<style type="text/css">
rect {fill:yellow;stroke:red;stroke-width:10}
text {fill:black;font-size:800}
</style>
</defs>
<g id="all" transform="translate(2000,2000)">
<xsl:apply-templates select="box"/>
</g>
</svg>
</xsl:template>
<xsl:template match="box">
<g>
<xsl:attribute name="transform"><xsl:value-of
select="concat('translate(',count(ancestor::*) * 8000 ,',',count(preceding::*)*3000,')')"/></xsl:attribute>
<rect width="5000"
height="2000"/>
<text x="200" y="1000" pointer-events="none">
<xsl:value-of select="@caption"/>
</text>
</g>
<xsl:apply-templates select="box"/>
</xsl:template>
</xsl:stylesheet>
--
Joris Gillis (
http://www.ticalc.org/cgi-bin/acct-v...i?userid=38041)
Ceterum censeo XML omnibus esse utendum