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