Code

Extensions. Fix EOL inconsistencies (Bug #314381).
[inkscape.git] / share / extensions / aisvg.xslt
1 <?xml version="1.0"?>
2 <xsl:stylesheet  xml:space="default" version="1.0" 
3 xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
4 xmlns="http://www.w3.org/2000/svg"
5 xmlns:svg="http://www.w3.org/2000/svg"
6 xmlns:xlink="http://www.w3.org/1999/xlink"
7 xmlns:x="http://ns.adobe.com/Extensibility/1.0/" 
8 xmlns:i="http://ns.adobe.com/AdobeIllustrator/10.0/" 
9 xmlns:graph="http://ns.adobe.com/Graphs/1.0/" 
10 xmlns:a="http://ns.adobe.com/AdobeSVGViewerExtensions/3.0/" 
11 xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
12 >
13 <xsl:output indent="yes"/>
14         <xsl:template match="/">
15                         <xsl:apply-templates />
16         </xsl:template>
17   <xsl:template match="svg:svg/svg:switch[count(*)=2][name(*[1])='foreignObject']">
18                 <xsl:apply-templates select="*[not(name()='foreignObject')]/*"/>
19   </xsl:template>
20         <xsl:template match="svg:svg/svg:g | svg:g[@i:extraneous='self']/svg:g">
21                 <xsl:copy>
22       <xsl:attribute name="inkscape:groupmode">layer</xsl:attribute>
23                         <xsl:apply-templates select="@*|*"/>
24     </xsl:copy>
25   </xsl:template>
26         <xsl:template match="*">
27                 <xsl:copy>
28                 <xsl:apply-templates select="@*|node()|text"/>
29                 </xsl:copy>
30         </xsl:template>
31         <xsl:template match="@*">
32                 <xsl:copy/>
33         </xsl:template>
34         <xsl:template match="i:*|@i:*|x:*|@x:*|graph:*|@graph:*|a:*|@a:*">
35         </xsl:template>
36 </xsl:stylesheet>