3 <xsl:stylesheet version="1.0"
4 xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
5 xmlns:helm="http://www.cs.unibo.it/helm"
6 xmlns="http://www.w3.org/1999/xhtml"
9 <xsl:output method="html" encoding="UTF-8"/>
11 <xsl:param name="CICURI" select="''" />
12 <xsl:param name="interfaceURL" select="''" />
14 <xsl:template match="ls">
19 font-family: sans-serif;
23 url(<xsl:value-of select="$interfaceURL"/>/icons/theory.png)
27 url(<xsl:value-of select="$interfaceURL"/>/icons/folder.png)
31 url(<xsl:value-of select="$interfaceURL"/>/icons/object.png)
33 a.theory { text-decoration: none; }
34 a.folder { text-decoration: none; }
35 a.object { text-decoration: none; }
40 <xsl:apply-templates select="object[@name='index.theory']"/>
41 <!-- sorting: folders interleaved with theories, then objects-->
43 select="section|object[substring-after(@name,'.')='theory' and
44 not(@name='index.theory')]">
45 <xsl:sort select="translate(concat(@name,string(.)),'abcdefghijklmnopqrstuvwxyz','ABCDEFGHIJKLMNOPQRSTUVWXYZ')" />
46 </xsl:apply-templates>
48 select="object[not(substring-after(@name,'.')='theory')]" >
49 <xsl:sort select="translate(concat(@name,string(.)),'abcdefghijklmnopqrstuvwxyz','ABCDEFGHIJKLMNOPQRSTUVWXYZ')" />
50 </xsl:apply-templates>
56 <xsl:template match="section">
58 <a class="folder" href="{concat($CICURI, text(), '/')}"
59 helm:helm_link="href">
60 <xsl:value-of select="text()" />
62 <xsl:text>/</xsl:text>
66 <xsl:template match="object">
68 <xsl:when test="substring-after(@name, '.')='theory'">
70 <a class="theory" href="{concat($CICURI, @name)}"
71 helm:helm_link="href">
72 <xsl:value-of select="@name" />
79 href="{concat('cic:', substring-after($CICURI, ':'), @name)}"
80 helm:helm_link="href">
81 <xsl:value-of select="@name" />