1 <?xml version=
"1.0" encoding=
"UTF-8"?>
3 <!-- This file is part of Shapes. -->
5 <!-- Shapes is free software: you can redistribute it and/or modify -->
6 <!-- it under the terms of the GNU General Public License as published by -->
7 <!-- the Free Software Foundation, either version 3 of the License, or -->
8 <!-- any later version. -->
10 <!-- Shapes is distributed in the hope that it will be useful, -->
11 <!-- but WITHOUT ANY WARRANTY; without even the implied warranty of -->
12 <!-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -->
13 <!-- GNU General Public License for more details. -->
15 <!-- You should have received a copy of the GNU General Public License -->
16 <!-- along with Shapes. If not, see <http://www.gnu.org/licenses/>. -->
18 <!-- Copyright 2008 Henrik Tidefelt -->
20 <xsl:stylesheet version=
"2.0"
21 xmlns:
xsl=
"http://www.w3.org/1999/XSL/Transform">
22 <xsl:output method=
"xml" indent=
"no" />
24 <xsl:include href=
"../../formats/html.xsl" />
25 <xsl:include href=
"../../syntax/formats/syntax-html.xsl" />
27 <xsl:template match=
"/book">
30 <title><xsl:apply-templates select=
"title" /></title>
31 <xsl:element name=
"link">
32 <xsl:attribute name=
"rel">stylesheet
</xsl:attribute>
33 <xsl:attribute name=
"href"><xsl:value-of select=
"/book/base/@href" />shapes.css
</xsl:attribute>
37 <h1><xsl:apply-templates select=
"title" /></h1>
39 <xsl:apply-templates select=
"top" />
40 <xsl:for-each select=
"section">
41 <h2><xsl:apply-templates select=
"title" /></h2>
42 <xsl:apply-templates select=
"top" />
43 <xsl:apply-templates select=
"body" />
44 <xsl:for-each select=
"section">
45 <h3><xsl:apply-templates select=
"title" /></h3>
46 <xsl:apply-templates select=
"top" />
47 <xsl:apply-templates select=
"body" />
48 <xsl:for-each select=
"section">
49 <h4><xsl:apply-templates select=
"title" /></h4>
50 <xsl:apply-templates select=
"top" />
51 <xsl:apply-templates select=
"body" />
60 <xsl:template match=
"index-of-books">
62 <xsl:apply-templates select=
"/book/external/book | /book/external/man | /book/external/group" />
66 <xsl:template match=
"external//book">
68 <xsl:element name=
"a">
69 <xsl:attribute name=
"href"><xsl:value-of select=
"/book/base/@href" /><xsl:apply-templates select=
"meta-selflink" /></xsl:attribute>
70 <b><xsl:apply-templates select=
"title" /></b>
72 <xsl:apply-templates select=
"description" />
76 <xsl:template match=
"external//man">
78 <xsl:element name=
"a">
79 <xsl:attribute name=
"href"><xsl:value-of select=
"/book/base/@href" /><xsl:apply-templates select=
"manhead/meta-selflink" /></xsl:attribute>
80 <b><xsl:apply-templates select=
"manhead/center-header" /></b>
82 <xsl:apply-templates select=
"manhead/description" />
86 <xsl:template match=
"external//group">
88 <b><xsl:apply-templates select=
"title" /></b>
89 <xsl:apply-templates select=
"description" />
91 <xsl:apply-templates select=
"book | man | group" />