Merge branch 'ht/graphs'
[shapes.git] / doc / parts / formats / man.xsl
blobc9fad100f7c613b78dbcbae41863949d44764bba
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, 2013 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-DAG">DAG</xsl:template>
30 <xsl:template match="str-PostScript">PostScript</xsl:template>
31 <xsl:template match="str-Shapes">Shapes</xsl:template>
32 <xsl:template match="str-shapes-mode">shapes-mode</xsl:template>
33 <xsl:template match="str-TeX">TeX</xsl:template>
34 <xsl:template match="str-LaTeX">LaTeX</xsl:template>
35 <xsl:template match="str-pdfLaTeX">pdfLaTeX</xsl:template>
36 <xsl:template match="str-MetaPost">MetaPost</xsl:template>
37 <xsl:template match="str-C-plus-plus">C++</xsl:template>
38 <xsl:template match="str-UTF-8">UTF-8</xsl:template>
39 <xsl:template match="str-2D">2D</xsl:template>
40 <xsl:template match="str-3D">3D</xsl:template>
42 <xsl:template match="abbr-etc">etc</xsl:template>
44 <xsl:template match="char-cdot">*</xsl:template>
45 <xsl:template match="char-bullet">#</xsl:template>
46 <xsl:template match="char-str-open">("</xsl:template>
47 <xsl:template match="char-str-close">")</xsl:template>
49 <xsl:template match="physical"><xsl:apply-templates select="scalar" /><xsl:apply-templates select="unit" /></xsl:template>
50 <xsl:template match="sci-fmt[@mantissa,@exp]"><xsl:value-of select="@mantissa" />e<xsl:value-of select="@exp" /></xsl:template>
51 <xsl:template match="quote">"<xsl:apply-templates />"</xsl:template>
53 <xsl:template match="tol-param"><xsl:text>
54 .ensure-line-break.B </xsl:text><xsl:value-of select="@name" /><xsl:text>
55 .ensure-line-break</xsl:text></xsl:template>
57 <xsl:template match="filename"><xsl:text>
58 .ensure-line-break.I </xsl:text><xsl:value-of select="." /><xsl:text>
59 .ensure-line-break</xsl:text></xsl:template>
61 <xsl:template match="p"><xsl:apply-templates/><xsl:text>
63 </xsl:text></xsl:template>
65 <xsl:template match="command-line"><xsl:text>
66 .br
67 .ensure-line-break</xsl:text><xsl:apply-templates/><xsl:text>
69 </xsl:text></xsl:template>
71 <xsl:template match="env-var[@name]"><xsl:value-of select="@name" /></xsl:template>
73 <xsl:template match="lexerregexp">
74 <xsl:apply-templates/>
75 </xsl:template>
77 <xsl:template name="format-value-name">
78 <xsl:param name="name" />
79 <xsl:text>
80 .ensure-line-break.I </xsl:text><xsl:value-of select="$name" /><xsl:text>
81 .ensure-line-break</xsl:text>
82 </xsl:template>
83 <xsl:template match="binding[@name and not(@extension)]">
84 <xsl:call-template name="format-value-name">
85 <xsl:with-param name="name"><xsl:value-of select="@name" /></xsl:with-param>
86 </xsl:call-template>
87 </xsl:template>
88 <xsl:template match="binding[@name and @extension]">
89 <xsl:call-template name="format-value-name">
90 <xsl:with-param name="name"><xsl:value-of select="@name" /></xsl:with-param>
91 </xsl:call-template>
92 <xsl:text> (in the extension </xsl:text><xsl:value-of select="@extension" /><xsl:text>)</xsl:text>
93 </xsl:template>
94 <xsl:template match="user-binding[@name]">
95 <xsl:call-template name="format-value-name">
96 <xsl:with-param name="name"><xsl:value-of select="@name" /></xsl:with-param>
97 </xsl:call-template>
98 </xsl:template>
100 </xsl:stylesheet>