<?xml version='1.0'?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
 <xsl:output method="xml" omit-xml-declaration="yes" indent="yes" />

<xsl:template match='Path'>
 <xsl:element name='Path'>
  <xsl:attribute name='d'>
   <xsl:apply-templates mode='in_path' />
  </xsl:attribute>
 </xsl:element>
</xsl:template>

<xsl:template match='Move' mode='in_path'>
 <xsl:choose>
  <xsl:when test='@position="absolute"'><xsl:text>M</xsl:text></xsl:when>
  <xsl:otherwise><xsl:text>m</xsl:text></xsl:otherwise>
 </xsl:choose>
 <xsl:value-of select="x" /><xsl:text>,</xsl:text><xsl:value-of select="y" />
</xsl:template>

<xsl:template match='Line' mode='in_path'>
 <xsl:choose>
  <xsl:when test='@position="absolute"'><xsl:text>L</xsl:text></xsl:when>
  <xsl:otherwise><xsl:text>l</xsl:text></xsl:otherwise>
 </xsl:choose>
 <xsl:value-of select="x" /><xsl:text>,</xsl:text><xsl:value-of select="y" />
</xsl:template>

<xsl:template match='HLine' mode='in_path'>
 <xsl:choose>
  <xsl:when test='@position="absolute"'><xsl:text>H</xsl:text></xsl:when>
  <xsl:otherwise><xsl:text>h</xsl:text></xsl:otherwise>
 </xsl:choose>
 <xsl:value-of select='x' />
</xsl:template>

<xsl:template match='VLine' mode='in_path'>
 <xsl:choose>
  <xsl:when test='@position="absolute"'><xsl:text>V</xsl:text></xsl:when>
  <xsl:otherwise><xsl:text>v</xsl:text></xsl:otherwise>
 </xsl:choose>
 <xsl:value-of select='y' />
</xsl:template>

<xsl:template match='Cubic' mode='in_path'>
 <xsl:choose>
  <xsl:when test='@position="absolute"'><xsl:text>C</xsl:text></xsl:when>
   <xsl:otherwise><xsl:text>c</xsl:text></xsl:otherwise>
 </xsl:choose>
  <xsl:value-of select='xc1' /><xsl:text>,</xsl:text>
  <xsl:value-of select='yc1' /><xsl:text>,</xsl:text>
  <xsl:value-of select='xc2' /><xsl:text>,</xsl:text>
  <xsl:value-of select='yc2' /><xsl:text>,</xsl:text>
  <xsl:value-of select='x' /><xsl:text>,</xsl:text>
  <xsl:value-of select='y' />
 </xsl:template>

<xsl:template match='SCubic' mode='in_path'>
 <xsl:choose>
  <xsl:when test='@position="absolute"'>
   <xsl:text>S</xsl:text>
  </xsl:when>
  <xsl:otherwise>
   <xsl:text>s</xsl:text>
  </xsl:otherwise>
 </xsl:choose>
 <xsl:value-of select='xc2' /><xsl:text>,</xsl:text>
 <xsl:value-of select='yc2' /><xsl:text>,</xsl:text>
 <xsl:value-of select='x' /><xsl:text>,</xsl:text>
 <xsl:value-of select='y' />  
</xsl:template>

<xsl:template match='Quadratic' mode='in_path'>
 <xsl:choose>
  <xsl:when test='@position="absolute"'>
   <xsl:text>Q</xsl:text>
  </xsl:when>
  <xsl:otherwise>
   <xsl:text>q</xsl:text>
  </xsl:otherwise>
 </xsl:choose>
 <xsl:value-of select='xc' /><xsl:text>,</xsl:text>
 <xsl:value-of select='yc' /><xsl:text>,</xsl:text>
 <xsl:value-of select='x' /><xsl:text>,</xsl:text>
 <xsl:value-of select='y' /> 
</xsl:template>


<xsl:template match='SQuadratic' mode='in_path'>
 <xsl:choose>
  <xsl:when test='@position="absolute"'>
   <xsl:text>T</xsl:text>
  </xsl:when>
  <xsl:otherwise>
   <xsl:text>t</xsl:text>
  </xsl:otherwise>
 </xsl:choose>
 <xsl:value-of select='x' /><xsl:text>,</xsl:text>
 <xsl:value-of select='y' />  
</xsl:template>


<xsl:template match='Arc' mode='in_path'>
 <xsl:choose>
  <xsl:when test='@position="absolute"'>
   <xsl:text>A</xsl:text>
  </xsl:when>
  <xsl:otherwise>
   <xsl:text>a</xsl:text>
  </xsl:otherwise>
 </xsl:choose>
 <xsl:value-of select='rx' /><xsl:text>,</xsl:text>
 <xsl:value-of select='ry' /><xsl:text>,</xsl:text>
 <xsl:value-of select='rot' /><xsl:text>,</xsl:text>
 <xsl:value-of select='lf' /><xsl:text>,</xsl:text>
 <xsl:value-of select='sf' /><xsl:text>,</xsl:text>
 <xsl:value-of select='x' /><xsl:text>,</xsl:text>
 <xsl:value-of select='y' />  
</xsl:template>

<xsl:template match='close' mode='in_path'>
 <xsl:text>Z</xsl:text>
</xsl:template>


</xsl:stylesheet><!-- Stylus Studio meta-information - (c) 2004-2005. Progress Software Corporation. All rights reserved.
<metaInformation>
<scenarios ><scenario default="yes" name="Scenario1" userelativepaths="yes" externalpreview="no" url="test.xml" htmlbaseurl="" outputurl="..\SVG\test.xml" processortype="saxon8" profilemode="0" profiledepth="" profilelength="" urlprofilexml="" commandline="" additionalpath="" additionalclasspath="" postprocessortype="none" postprocesscommandline="" postprocessadditionalpath="" postprocessgeneratedext=""/></scenarios><MapperMetaTag><MapperInfo srcSchemaPathIsRelative="yes" srcSchemaInterpretAsXML="no" destSchemaPath="" destSchemaRoot="" destSchemaPathIsRelative="yes" destSchemaInterpretAsXML="no"/><MapperBlockPosition><template match="path"></template></MapperBlockPosition></MapperMetaTag>
</metaInformation>
-->