Doc: Initiate transition to next generation documentation
[shapes.git] / doc / parts / formats / man.xsl
blob681b88b21eec18e9bdd29203fb9e2b73c7cd7ce2
1 <?xml version="1.0" encoding="UTF-8"?>
3 <!-- This file is part of Shapes. -->
4 <!-- -->
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. -->
9 <!-- -->
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. -->
14 <!-- -->
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/>. -->
17 <!-- -->
18 <!-- Copyright 2008, 2010 Henrik Tidefelt -->
20 <xsl:stylesheet version="2.0"
21 xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
23 <xsl:template match="str-PDF">PDF</xsl:template>
24 <xsl:template match="str-HTML">HTML</xsl:template>
25 <xsl:template match="str-XML">XML</xsl:template>
26 <xsl:template match="str-SVG">SVG</xsl:template>
27 <xsl:template match="str-PNG">PNG</xsl:template>
28 <xsl:template match="str-JPEG">JPEG</xsl:template>
29 <xsl:template match="str-PostScript">PostScript</xsl:template>
30 <xsl:template match="str-Shapes">Shapes</xsl:template>
31 <xsl:template match="str-shapes-mode">shapes-mode</xsl:template>
32 <xsl:template match="str-TeX">TeX</xsl:template>
33 <xsl:template match="str-LaTeX">LaTeX</xsl:template>
34 <xsl:template match="str-pdfLaTeX">pdfLaTeX</xsl:template>
35 <xsl:template match="str-MetaPost">MetaPost</xsl:template>
36 <xsl:template match="str-C-plus-plus">C++</xsl:template>
37 <xsl:template match="str-UTF-8">UTF-8</xsl:template>
38 <xsl:template match="str-2D">2D</xsl:template>
39 <xsl:template match="str-3D">3D</xsl:template>
41 <xsl:template match="abbr-etc">etc</xsl:template>
43 <xsl:template match="char-cdot">*</xsl:template>
44 <xsl:template match="char-bullet">#</xsl:template>
45 <xsl:template match="char-str-open">("</xsl:template>
46 <xsl:template match="char-str-close">")</xsl:template>
48 <xsl:template match="physical"><xsl:apply-templates select="scalar" /><xsl:apply-templates select="unit" /></xsl:template>
49 <xsl:template match="sci-fmt[@mantissa,@exp]"><xsl:value-of select="@mantissa" />e<xsl:value-of select="@exp" /></xsl:template>
50 <xsl:template match="quote">"<xsl:apply-templates />"</xsl:template>
52 <xsl:template match="tol-param"><xsl:text>
53 .ensure-line-break.B </xsl:text><xsl:value-of select="@name" /><xsl:text>
54 .ensure-line-break</xsl:text></xsl:template>
56 <xsl:template match="filename"><xsl:text>
57 .ensure-line-break.I </xsl:text><xsl:value-of select="." /><xsl:text>
58 .ensure-line-break</xsl:text></xsl:template>
60 <xsl:template match="p"><xsl:apply-templates/><xsl:text>
62 </xsl:text></xsl:template>
64 <xsl:template match="command-line"><xsl:text>
65 .br
66 .ensure-line-break</xsl:text><xsl:apply-templates/><xsl:text>
68 </xsl:text></xsl:template>
70 <xsl:template match="env-var[@name]"><xsl:value-of select="@name" /></xsl:template>
72 <xsl:template match="lexerregexp">
73 <xsl:apply-templates/>
74 </xsl:template>
76 <xsl:template name="format-value-name">
77 <xsl:param name="name" />
78 <xsl:text>
79 .ensure-line-break.I </xsl:text><xsl:value-of select="$name" /><xsl:text>
80 .ensure-line-break</xsl:text>
81 </xsl:template>
82 <xsl:template match="binding[@name and not(@extension)]">
83 <xsl:call-template name="format-value-name">
84 <xsl:with-param name="name"><xsl:value-of select="@name" /></xsl:with-param>
85 </xsl:call-template>
86 </xsl:template>
87 <xsl:template match="binding[@name and @extension]">
88 <xsl:call-template name="format-value-name">
89 <xsl:with-param name="name"><xsl:value-of select="@name" /></xsl:with-param>
90 </xsl:call-template>
91 <xsl:text> (in the extension </xsl:text><xsl:value-of select="@extension" /><xsl:text>)</xsl:text>
92 </xsl:template>
93 <xsl:template match="user-binding[@name]">
94 <xsl:call-template name="format-value-name">
95 <xsl:with-param name="name"><xsl:value-of select="@name" /></xsl:with-param>
96 </xsl:call-template>
97 </xsl:template>
99 </xsl:stylesheet>