1.8.52 Toolbar layout is saved now.
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!DOCTYPE xsl:stylesheet
4 <!-- Namespace for XHTML -->
5 <!ENTITY xhtmlns "http://www.w3.org/1999/xhtml">
9 Author : Uwe Drechsel <vym@InSilmaril.de>
10 Credits to : Thomas Schraitle for his patience in explaining XSL to me
11 Description : transforms vym maps into KDE Bookmarks
14 <xsl:stylesheet version="1.0"
15 xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
16 xmlns:date="http://exslt.org/dates-and-times"
17 extension-element-prefixes="date">
20 <xsl:output method="xml"
21 doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
22 doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"
25 media-type="application/xhtml+xml"/>
27 <!-- ======================================= -->
29 <xsl:template match="/">
30 <xsl:apply-templates/>
34 <xsl:template match="text()"/>
37 <xsl:template match="vymmap">
39 <xsl:apply-templates/>
44 <xsl:template match="mapcenter">
46 <xsl:apply-templates/>
50 <xsl:template match="branch">
52 <xsl:when test="heading='KDE'">
53 <xsl:apply-templates select="branch" mode="kde"/>
55 <xsl:when test=". = 'Firefox'">
56 <xsl:apply-templates mode="firefox"/>
60 <xsl:apply-templates/>
64 <xsl:apply-templates/>
67 <xsl:template match="heading" mode="kde">
69 <xsl:value-of select="normalize-space (.)"/>
73 <xsl:when test=". = 'KDE'">
74 <xsl:apply-templates mode="kde"/>
77 <xsl:apply-templates/>
81 <xsl:apply-templates/>
85 <xsl:template match="branch" mode="kde">
87 <xsl:when test="@url">
88 <xsl:element name="bookmark">
89 <xsl:attribute name="href" ><xsl:value-of select="@url" />
91 <xsl:apply-templates mode="kde"/>
96 <xsl:when test="contains(heading,'***')">
97 <separator folded="yes" />
100 <folder folded="yes" icon="bookmark_folder">
101 <xsl:apply-templates mode="kde"/>
111 <xsl:text> </xsl:text>
113 <xsl:message> WARNING: No @url attribute given of "<xsl:value-of select="normalize-space(heading)"/>"</xsl:message>
115 <xsl:template match="branch">
117 <xsl:when test="@url">
118 <xsl:text> *nokde* </xsl:text>
119 <xsl:value-of select="@url"/>
120 <xsl:text> </xsl:text>
123 <xsl:message> WARNING: No @url attribute given of "<xsl:value-of select="normalize-space(heading)"/>"</xsl:message>
127 <xsl:apply-templates/>