removing RCS tags
[Samba.git] / docs / docbook / xslt / db2latex / refentry.mod.xsl
blob52d2b297d527f345f0acbe44df741e805c7c37ed
1 <?xml version='1.0'?>
2 <!--#############################################################################
3 |- #############################################################################
4 |
5 | PURPOSE:
6 + ############################################################################## -->
8 <xsl:stylesheet
9 xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
10 xmlns:doc="http://nwalsh.com/xsl/documentation/1.0"
11 exclude-result-prefixes="doc" version='1.0'>
15 <!--############################################################################# -->
16 <!-- DOCUMENTATION -->
17 <doc:reference id="refentry" xmlns="">
18 <referenceinfo>
19 <releaseinfo role="meta">
20 </releaseinfo>
21 <authogroup>
22 <author> <firstname>Ramon</firstname> <surname>Casellas</surname> </author>
23 <author> <firstname>James</firstname> <surname>Devenish</surname> </author>
24 </authogroup>
25 <copyright>
26 <year>2000</year> <year>2001</year> <year>2002</year> <year>2003</year>
27 <holder>Ramon Casellas</holder>
28 </copyright>
29 </referenceinfo>
31 <title>References and Entries <filename>refentry.mod.xsl</filename></title>
32 <partintro>
33 <section><title>Introduction</title>
34 <para></para>
35 </section>
36 </partintro>
37 </doc:reference>
41 <!--#############################################################################
42 | REFERENCE
43 |- #############################################################################
45 + ############################################################################## -->
46 <xsl:template match="reference">
47 <xsl:call-template name="map.begin"/>
48 <xsl:apply-templates select="partintro"/>
49 <xsl:apply-templates select="*[local-name(.) != 'partintro']"/>
50 </xsl:template>
52 <xsl:template match="reference" mode="division.number">
53 <xsl:number from="book" count="reference" format="I."/>
54 </xsl:template>
56 <xsl:template match="reference/docinfo"/>
57 <xsl:template match="reference/title"/>
58 <xsl:template match="reference/subtitle"/>
62 <!--#############################################################################
63 | REFENTRY
64 |- #############################################################################
66 + ############################################################################## -->
67 <xsl:template match="refentry">
68 <xsl:variable name="refmeta" select=".//refmeta"/>
69 <xsl:variable name="refentrytitle" select="$refmeta//refentrytitle"/>
70 <xsl:variable name="refnamediv" select=".//refnamediv"/>
71 <xsl:variable name="refname" select="$refnamediv//refname"/>
72 <xsl:variable name="title">
73 <xsl:choose>
74 <xsl:when test="$refentrytitle">
75 <xsl:apply-templates select="$refentrytitle[1]" mode="title"/>
76 </xsl:when>
77 <xsl:when test="$refname">
78 <xsl:apply-templates select="$refname[1]" mode="title"/>
79 </xsl:when>
80 <xsl:otherwise></xsl:otherwise>
81 </xsl:choose>
82 </xsl:variable>
83 <xsl:call-template name="map.begin">
84 <xsl:with-param name="string" select="$title"/>
85 </xsl:call-template>
86 <xsl:apply-templates/>
87 </xsl:template>
89 <xsl:template match="refentrytitle|refname" mode="title">
90 <xsl:apply-templates/>
91 </xsl:template>
93 <xsl:template match="refentry/docinfo|refentry/refentryinfo"/>
94 <xsl:template match="refmeta"/>
96 <xsl:template match="manvolnum">
97 <xsl:if test="$refentry.xref.manvolnum != 0">
98 <xsl:text>(</xsl:text>
99 <xsl:apply-templates/>
100 <xsl:text>)</xsl:text>
101 </xsl:if>
102 </xsl:template>
104 <xsl:template match="refmiscinfo"/>
106 <xsl:template match="refentrytitle">
107 <xsl:call-template name="inline.charseq"/>
108 </xsl:template>
110 <xsl:template match="refnamediv">
111 <xsl:call-template name="block.object"/>
112 </xsl:template>
114 <xsl:template match="refname">
115 <xsl:apply-templates/>
116 <xsl:if test="not (preceding-sibling::refname)">
117 <xsl:text>&#10;\subsection*{</xsl:text>
118 <xsl:if test="$refentry.generate.name != 0">
119 <xsl:call-template name="gentext.element.name"/>
120 </xsl:if>
121 <xsl:text>}&#10;</xsl:text>
122 </xsl:if>
123 <xsl:apply-templates/>
124 <xsl:if test="following-sibling::refname">
125 <xsl:text>, </xsl:text>
126 </xsl:if>
127 </xsl:template>
130 <xsl:template match="refpurpose">
131 <xsl:text> $-$ </xsl:text>
132 <xsl:apply-templates/>
133 </xsl:template>
135 <xsl:template match="refdescriptor">
136 <!-- todo: finish this -->
137 </xsl:template>
139 <xsl:template match="refclass">
140 <xsl:if test="@role">
141 <xsl:value-of select="@role"/>
142 <xsl:text>: </xsl:text>
143 </xsl:if>
144 <xsl:apply-templates/>
145 </xsl:template>
149 <!--#############################################################################
150 | REFSYNOPSIS
151 |- #############################################################################
153 + ############################################################################## -->
155 <xsl:template match="refsynopsisdiv">
156 <xsl:call-template name="label.id"/>
157 <xsl:text>&#10;\subsection*{Synopsis}&#10;</xsl:text>
158 <xsl:apply-templates/>
159 </xsl:template>
161 <xsl:template match="refsynopsisdivinfo"></xsl:template>
162 <xsl:template match="refsynopsisdiv/title"></xsl:template>
165 <!--#############################################################################
166 | REFSECTS
167 |- #############################################################################
169 + ############################################################################## -->
171 <xsl:template match="refsect1|refsect2|refsect3">
172 <xsl:call-template name="map.begin"/>
173 <xsl:apply-templates/>
174 </xsl:template>
176 <xsl:template match="refsect1/title"/>
177 <xsl:template match="refsect2/title"/>
178 <xsl:template match="refsect3/title"/>
179 <xsl:template match="refsect1info"/>
180 <xsl:template match="refsect2info"/>
181 <xsl:template match="refsect3info"/>
184 </xsl:stylesheet>