1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
|
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Common Template Reference</title>
<link rel="stylesheet" href="../reference.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<div class="reference">
<div class="titlepage">
<div>
<h1 class="title"><a name="d0e1"></a>Common Template Reference
</h1>
</div>
<div>
<h3 class="author">Norman Walsh</h3>
</div>
<div>
<p class="releaseinfo">
$Id: common.html,v 1.1 2002/05/15 17:22:23 isberg Exp $
</p>
</div>
<div>
<p class="copyright"><a href="../copyright.html">Copyright</a> © 1999, 2000 by Norman Walsh. <a href="../warranty.html">No Warranty</a>.
</p>
</div>
<hr>
</div>
<div class="partintro">
<div></div>
<div class="section"><a name="d0e24"></a><div class="titlepage">
<div>
<h2 class="title" style="clear: both"><a name="d0e24"></a>Introduction
</h2>
</div>
</div>
<p>This is technical reference documentation for the DocBook XSL
Stylesheets; it documents (some of) the parameters, templates, and
other elements of the stylesheets.
</p>
<p>This is not intended to be user documentation.
It is provided for developers writing customization layers for the
stylesheets, and for anyone who's interested in how it
works.
</p>
<p>Although I am trying to be thorough, this documentation is known
to be incomplete. Don't forget to read the source, too :-)
</p>
</div>
<div class="toc">
<p><b>Table of Contents</b></p>
<dl>
<dt><a href="#template.is.component">is.component</a> - Tests if a given node is a component-level element
</dt>
<dt><a href="#template.is.section">is.section</a> - Tests if a given node is a section-level element
</dt>
<dt><a href="#template.section.level">section.level</a> - Returns the hierarchical level of a section.
</dt>
<dt><a href="#template.qanda.section.level">qanda.section.level</a> - Returns the hierarchical level of a QandASet.
</dt>
<dt><a href="#template.select.mediaobject">select.mediaobject</a> - Selects an appropriate media object from a list
</dt>
<dt><a href="#template.is.acceptable.mediaobject">is.acceptable.mediaobject</a> - Returns '1' if the specified media object is recognized.
</dt>
<dt><a href="#template.check.id.unique">check.id.unique</a> - Warn users about references to non-unique IDs
</dt>
<dt><a href="#template.check.idref.targets">check.idref.targets</a> - Warn users about incorrectly typed references
</dt>
</dl>
</div>
</div>
<hr>
<div class="refentry">
<h1 class="title"><a name="template.is.component"></a>is.component
</h1>
<div class="refnamediv"><a name="d0e40"></a><h2>Name</h2>is.component — Tests if a given node is a component-level element
</div>
<div class="refsynopsisdiv"><a name="d0e45"></a><h2>Synopsis</h2><pre class="synopsis"><xsl:template name="is.component">
<xsl:param name="node" select="."/>
...
</xsl:template></pre></div>
<div class="refdescription"><a name="d0e48"></a>
<p>This template returns '1' if the specified node is a component
(Chapter, Appendix, etc.), and '0' otherwise.
</p>
</div>
<div class="refparameter"><b><a name="d0e53"></a>Parameters</b>
<div class="variablelist">
<dl>
<dt><a name="d0e56"></a><span class="term">node</span></dt>
<dd>
<p><a name="d0e59"></a>The node which is to be tested.
</p>
</dd>
</dl>
</div>
</div>
<div class="refreturn"><b><a name="d0e63"></a>Returns</b>
<p>This template returns '1' if the specified node is a component
(Chapter, Appendix, etc.), and '0' otherwise.
</p>
</div>
</div>
<hr>
<div class="refentry">
<h1 class="title"><a name="template.is.section"></a>is.section
</h1>
<div class="refnamediv"><a name="d0e69"></a><h2>Name</h2>is.section — Tests if a given node is a section-level element
</div>
<div class="refsynopsisdiv"><a name="d0e74"></a><h2>Synopsis</h2><pre class="synopsis"><xsl:template name="is.section">
<xsl:param name="node" select="."/>
...
</xsl:template></pre></div>
<div class="refdescription"><a name="d0e77"></a>
<p>This template returns '1' if the specified node is a section
(Section, Sect1, Sect2, etc.), and '0' otherwise.
</p>
</div>
<div class="refparameter"><b><a name="d0e82"></a>Parameters</b>
<div class="variablelist">
<dl>
<dt><a name="d0e85"></a><span class="term">node</span></dt>
<dd>
<p><a name="d0e88"></a>The node which is to be tested.
</p>
</dd>
</dl>
</div>
</div>
<div class="refreturn"><b><a name="d0e92"></a>Returns</b>
<p>This template returns '1' if the specified node is a section
(Section, Sect1, Sect2, etc.), and '0' otherwise.
</p>
</div>
</div>
<hr>
<div class="refentry">
<h1 class="title"><a name="template.section.level"></a>section.level
</h1>
<div class="refnamediv"><a name="d0e98"></a><h2>Name</h2>section.level — Returns the hierarchical level of a section.
</div>
<div class="refsynopsisdiv"><a name="d0e103"></a><h2>Synopsis</h2><pre class="synopsis"><xsl:template name="section.level">
<xsl:param name="node" select="."/>
...
</xsl:template></pre></div>
<div class="refdescription"><a name="d0e106"></a>
<p>This template calculates the hierarchical level of a section.
Hierarchically, components are top level, so a
<tt>sect1</tt> is at level 2, <tt>sect3</tt> is
at level 3, etc.
</p>
<p>Recursive sections are calculated down to the sixth level.</p>
</div>
<div class="refparameter"><b><a name="d0e123"></a>Parameters</b>
<div class="variablelist">
<dl>
<dt><a name="d0e126"></a><span class="term">node</span></dt>
<dd>
<p><a name="d0e129"></a>The section node for which the level should be calculated.
Defaults to the context node.
</p>
</dd>
</dl>
</div>
</div>
<div class="refreturn"><b><a name="d0e133"></a>Returns</b>
<p>The section level, 2, 3, etc.
</p>
</div>
</div>
<hr>
<div class="refentry">
<h1 class="title"><a name="template.qanda.section.level"></a>qanda.section.level
</h1>
<div class="refnamediv"><a name="d0e145"></a><h2>Name</h2>qanda.section.level — Returns the hierarchical level of a QandASet.
</div>
<div class="refsynopsisdiv"><a name="d0e150"></a><h2>Synopsis</h2><pre class="synopsis"><xsl:template name="qanda.section.level"/></pre></div>
<div class="refdescription"><a name="d0e153"></a>
<p>This template calculates the hierarchical level of a QandASet.
</p>
</div>
<div class="refreturn"><b><a name="d0e158"></a>Returns</b>
<p>The level, 1, 2, etc.
</p>
</div>
</div>
<hr>
<div class="refentry">
<h1 class="title"><a name="template.select.mediaobject"></a>select.mediaobject
</h1>
<div class="refnamediv"><a name="d0e170"></a><h2>Name</h2>select.mediaobject — Selects an appropriate media object from a list
</div>
<div class="refsynopsisdiv"><a name="d0e175"></a><h2>Synopsis</h2><pre class="synopsis"><xsl:template name="select.mediaobject">
<xsl:param name="olist" select="imageobject|imageobjectco |videoobject|audioobject|textobject"/>
<xsl:param name="count">1</xsl:param>
...
</xsl:template></pre></div>
<div class="refdescription"><a name="d0e178"></a>
<p>This template examines a list of media objects (usually the
children of a mediaobject or inlinemediaobject) and processes
the "right" object.
</p>
<p>This template relies on a template named "is.acceptable.mediaobject"
to determine if a given object is an acceptable graphic. The semantics
of media objects is that the first acceptable graphic should be used.
</p>
<p>If no acceptable object is located, nothing happens.</p>
</div>
<div class="refparameter"><b><a name="d0e189"></a>Parameters</b>
<div class="variablelist">
<dl>
<dt><a name="d0e192"></a><span class="term">olist</span></dt>
<dd>
<p><a name="d0e195"></a>The node list of potential objects to examine.
</p>
</dd>
</dl>
</div>
</div>
<div class="refreturn"><b><a name="d0e199"></a>Returns</b>
<p>Calls <xsl:apply-templates> on the selected object.</p>
</div>
</div>
<hr>
<div class="refentry">
<h1 class="title"><a name="template.is.acceptable.mediaobject"></a>is.acceptable.mediaobject
</h1>
<div class="refnamediv"><a name="d0e205"></a><h2>Name</h2>is.acceptable.mediaobject — Returns '1' if the specified media object is recognized.
</div>
<div class="refsynopsisdiv"><a name="d0e210"></a><h2>Synopsis</h2><pre class="synopsis"><xsl:template name="is.acceptable.mediaobject">
<xsl:param name="object"/>
...
</xsl:template></pre></div>
<div class="refdescription"><a name="d0e213"></a>
<p>This template examines a media object and returns '1' if the
object is recognized as a graphic.
</p>
</div>
<div class="refparameter"><b><a name="d0e218"></a>Parameters</b>
<div class="variablelist">
<dl>
<dt><a name="d0e221"></a><span class="term">object</span></dt>
<dd>
<p><a name="d0e224"></a>The media object to consider.
</p>
</dd>
</dl>
</div>
</div>
<div class="refreturn"><b><a name="d0e228"></a>Returns</b>
<p>0 or 1</p>
</div>
</div>
<hr>
<div class="refentry">
<h1 class="title"><a name="template.check.id.unique"></a>check.id.unique
</h1>
<div class="refnamediv"><a name="d0e234"></a><h2>Name</h2>check.id.unique — Warn users about references to non-unique IDs
</div>
<div class="refsynopsisdiv"><a name="d0e239"></a><h2>Synopsis</h2><pre class="synopsis"><xsl:template name="check.id.unique">
<xsl:param name="linkend"/>
...
</xsl:template></pre></div>
<div class="refdescription"><a name="d0e242"></a>
<p>If passed an ID in <tt>linkend</tt>,
<tt>check.id.unique</tt> prints
a warning message to the user if either the ID does not exist or
the ID is not unique.
</p>
</div>
</div>
<hr>
<div class="refentry">
<h1 class="title"><a name="template.check.idref.targets"></a>check.idref.targets
</h1>
<div class="refnamediv"><a name="d0e254"></a><h2>Name</h2>check.idref.targets — Warn users about incorrectly typed references
</div>
<div class="refsynopsisdiv"><a name="d0e259"></a><h2>Synopsis</h2><pre class="synopsis"><xsl:template name="check.idref.targets">
<xsl:param name="linkend"/>
<xsl:param name="element-list"/>
...
</xsl:template></pre></div>
<div class="refdescription"><a name="d0e262"></a>
<p>If passed an ID in <tt>linkend</tt>,
<tt>check.idref.targets</tt> makes sure that the element
pointed to by the link is one of the elements listed in
<tt>element-list</tt> and warns the user otherwise.
</p>
</div>
</div>
</div>
</body>
</html>
|