~ubuntu-branches/ubuntu/feisty/apache2/feisty

« back to all changes in this revision

Viewing changes to docs/manual/style/xsl/common.xsl

  • Committer: Bazaar Package Importer
  • Author(s): Andreas Barth
  • Date: 2006-12-09 21:05:45 UTC
  • mfrom: (0.6.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20061209210545-h70s0xaqc2v8vqr2
Tags: 2.2.3-3.2
* Non-maintainer upload.
* 043_ajp_connection_reuse: Patch from upstream Bugzilla, fixing a critical
  issue with regard to connection reuse in mod_proxy_ajp.
  Closes: #396265

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<?xml version="1.0"?>
 
2
 
 
3
<!--
 
4
 Licensed to the Apache Software Foundation (ASF) under one or more
 
5
 contributor license agreements.  See the NOTICE file distributed with
 
6
 this work for additional information regarding copyright ownership.
 
7
 The ASF licenses this file to You under the Apache License, Version 2.0
 
8
 (the "License"); you may not use this file except in compliance with
 
9
 the License.  You may obtain a copy of the License at
 
10
 
 
11
     http://www.apache.org/licenses/LICENSE-2.0
 
12
 
 
13
 Unless required by applicable law or agreed to in writing, software
 
14
 distributed under the License is distributed on an "AS IS" BASIS,
 
15
 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 
16
 See the License for the specific language governing permissions and
 
17
 limitations under the License.
 
18
-->
 
19
 
 
20
<!DOCTYPE xsl:stylesheet [
 
21
    <!ENTITY nbsp SYSTEM "util/nbsp.xml">
 
22
    <!ENTITY lf SYSTEM "util/lf.xml">
 
23
]>
 
24
<xsl:stylesheet version="1.0"
 
25
              xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
 
26
                  xmlns="http://www.w3.org/1999/xhtml">
 
27
 
 
28
<!--                                                                      -->
 
29
<!-- Please, don't hard-code output strings! Use the language             -->
 
30
<!-- files and the translation "stuff"...                                 -->
 
31
<!--                                                                      -->
 
32
 
 
33
<!-- Injected variables:                                                  -->
 
34
<!--   $is-chm          - (boolean) target is for CHM generation or not   -->
 
35
<!--   $is-zip          - (boolean) target is for ZIP generation or not   -->
 
36
<!--   $message         - (node-set) localized common text snippets       -->
 
37
<!--   $doclang         - (string) document language                      -->
 
38
<!--   $output-encoding - (string) MIME charset name of the output        -->
 
39
<!--                      encoding                                        -->
 
40
 
 
41
<!-- Constants used for case translation -->
 
42
<xsl:variable name="lowercase" select="'abcdefghijklmnopqrstuvwxyz'" />
 
43
<xsl:variable name="uppercase" select="'ABCDEFGHIJKLMNOPQRSTUVWXYZ'" />
 
44
 
 
45
<!-- space separated list of blockelements defined in common.dtd -->
 
46
<!--    used for inline content catching in <example>s           -->
 
47
<xsl:variable name="blockelements">
 
48
    p  example  note  table  ul  ol  dl  pre  img  blockquote
 
49
</xsl:variable>
 
50
 
 
51
<!-- relative path to /manual/ -->
 
52
<xsl:variable name="metafile" select="document(/*/@metafile)/metafile" />
 
53
<xsl:variable name="path"     select="$metafile/relpath" />
 
54
 
 
55
<!-- load outsourced page types -->
 
56
<xsl:include href="moduleindex.xsl" />
 
57
<xsl:include href="directiveindex.xsl" />
 
58
<xsl:include href="manualpage.xsl" />
 
59
<xsl:include href="synopsis.xsl" />
 
60
<xsl:include href="sitemap.xsl" />
 
61
<xsl:include href="indexpage.xsl" />
 
62
<xsl:include href="quickreference.xsl" />
 
63
<xsl:include href="faq.xsl" />
 
64
 
 
65
<!-- load utility snippets -->
 
66
<xsl:include href="util/modtrans.xsl" />
 
67
 
 
68
<!-- make sure, we set relative anchors only, if we're actually -->
 
69
<!-- transforming a modulefile (see <directive> template)       -->
 
70
<xsl:variable name="in-modulesynopsis" select="boolean(/modulesynopsis)" />
 
71
 
 
72
<!-- when referencing to a directory, we may need to complete the path -->
 
73
<!-- with the index file (for offline applications like *.chm files)   -->
 
74
<xsl:variable name="index-file">
 
75
    <xsl:if test="$is-chm or $is-zip">index.html</xsl:if>
 
76
</xsl:variable>
 
77
 
 
78
<!-- it may be desired to open external targets in a new window -->
 
79
<xsl:variable name="ext-target" select="boolean($is-chm)" />
 
80
 
 
81
<!-- #################################################################### -->
 
82
<!-- Utility templates for constructing pages                             -->
 
83
<!-- #################################################################### -->
 
84
 
 
85
<!-- ==================================================================== -->
 
86
<!-- HTML head                                                            -->
 
87
<!-- ==================================================================== -->
 
88
<xsl:template name="head">
 
89
<head>
 
90
    <!-- the meta element is necessary for offline handling like CHM -->
 
91
    <xsl:choose>
 
92
    <xsl:when test="$is-chm or $is-zip">
 
93
        <meta http-equiv="Content-Type"
 
94
                 content="text/html; charset={$output-encoding}" />
 
95
    </xsl:when>
 
96
    <xsl:otherwise>
 
97
        <xsl:comment>
 
98
            &lf;
 
99
            <xsl:text>        </xsl:text>
 
100
            <xsl:text>XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX</xsl:text>
 
101
            <xsl:text>XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX</xsl:text>
 
102
            &lf;
 
103
            <xsl:text>              </xsl:text>
 
104
            <xsl:text>This file is generated from xml source: </xsl:text>
 
105
            <xsl:text>DO NOT EDIT</xsl:text>
 
106
            &lf;
 
107
            <xsl:text>        </xsl:text>
 
108
            <xsl:text>XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX</xsl:text>
 
109
            <xsl:text>XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX</xsl:text>
 
110
            &lf;
 
111
            <xsl:text>      </xsl:text>
 
112
        </xsl:comment>
 
113
    </xsl:otherwise>
 
114
    </xsl:choose>&lf;
 
115
 
 
116
    <title>
 
117
        <xsl:choose>
 
118
        <xsl:when test="name">
 
119
            <xsl:value-of select="name"/>
 
120
        </xsl:when>
 
121
 
 
122
        <xsl:otherwise>
 
123
            <xsl:value-of select="title"/>
 
124
        </xsl:otherwise>
 
125
        </xsl:choose>
 
126
 
 
127
        <xsl:text> </xsl:text>
 
128
        <xsl:value-of select="normalize-space($message[@id='apachetitle'])"/>
 
129
    </title>&lf;
 
130
 
 
131
    <!-- chm files get a slightly different stylesheet -->
 
132
    <xsl:choose>
 
133
    <xsl:when test="$is-chm">
 
134
        <link type="text/css" rel="stylesheet" media="all"
 
135
              href="{$path}/style/css/manual-chm.css" />
 
136
    </xsl:when>
 
137
    <!-- zip packages do also -->
 
138
    <xsl:when test="$is-zip">
 
139
        <link title="Main stylesheet"  type="text/css" media="all"
 
140
                rel="stylesheet"
 
141
               href="{$path}/style/css/manual-zip.css" />&lf;
 
142
        <link title="No Sidebar - Default font size" type="text/css" media="all"
 
143
               rel="alternate stylesheet"
 
144
               href="{$path}/style/css/manual-zip-100pc.css"/>
 
145
    </xsl:when>
 
146
    <xsl:otherwise>
 
147
        <link title="Main stylesheet"  type="text/css" media="all"
 
148
                rel="stylesheet"
 
149
               href="{$path}/style/css/manual.css" />&lf;
 
150
        <link title="No Sidebar - Default font size" type="text/css" media="all"
 
151
               rel="alternate stylesheet"
 
152
               href="{$path}/style/css/manual-loose-100pc.css"/>
 
153
    </xsl:otherwise>
 
154
    </xsl:choose>&lf;
 
155
 
 
156
    <link type="text/css" media="print"
 
157
           rel="stylesheet"
 
158
           href="{$path}/style/css/manual-print.css"/>
 
159
 
 
160
    <!-- chm files do not need a favicon -->
 
161
    <xsl:if test="not($is-chm or $is-zip)">&lf;
 
162
        <link rel="shortcut icon" href="{$path}/images/favicon.ico" />
 
163
    </xsl:if>
 
164
</head>
 
165
</xsl:template>
 
166
<!-- /head -->
 
167
 
 
168
 
 
169
<!-- ==================================================================== -->
 
170
<!-- page top                                                             -->
 
171
<!-- ==================================================================== -->
 
172
<xsl:template name="top">
 
173
<div id="page-header">&lf;
 
174
    <xsl:call-template name="super-menu" />&lf;
 
175
 
 
176
    <p class="apache">
 
177
        <xsl:value-of select="normalize-space($message
 
178
                                              [@id='apachehttpserver'])"/>
 
179
    </p>&lf;
 
180
 
 
181
    <img src="{$path}/images/feather.gif" alt="" />
 
182
</div>&lf; <!-- /page-header -->
 
183
 
 
184
<div class="up">
 
185
    <a href="./{$index-file}">
 
186
        <xsl:if test="parentdocument">
 
187
            <xsl:attribute name="href">
 
188
                <xsl:value-of select="parentdocument/@href"/>
 
189
            </xsl:attribute>
 
190
 
 
191
            <xsl:call-template name="helper.uri.fix">
 
192
                <xsl:with-param name="uri" select="parentdocument/@href" />
 
193
            </xsl:call-template>
 
194
      </xsl:if>
 
195
 
 
196
      <img src="{$path}/images/left.gif" alt="&lt;-" title="&lt;-" />
 
197
    </a>
 
198
</div>&lf;
 
199
 
 
200
<div id="path">&lf;
 
201
    <a href="http://www.apache.org/">
 
202
        <xsl:if test="$ext-target">
 
203
            <xsl:attribute name="target">_blank</xsl:attribute>
 
204
        </xsl:if>
 
205
        <xsl:value-of select="$message[@id='apache']" />
 
206
    </a>
 
207
 
 
208
    <xsl:text> &gt; </xsl:text>
 
209
 
 
210
    <a href="http://httpd.apache.org/">
 
211
        <xsl:if test="$ext-target">
 
212
            <xsl:attribute name="target">_blank</xsl:attribute>
 
213
        </xsl:if>
 
214
        <xsl:value-of select="$message[@id='http-server']" />
 
215
    </a>
 
216
 
 
217
    <xsl:text> &gt; </xsl:text>
 
218
 
 
219
    <a href="http://httpd.apache.org/docs/">
 
220
        <xsl:if test="$ext-target">
 
221
            <xsl:attribute name="target">_blank</xsl:attribute>
 
222
        </xsl:if>
 
223
        <xsl:value-of select="$message[@id='documentation']" />
 
224
    </a>
 
225
 
 
226
    <xsl:if test="not(../indexpage)">
 
227
    <xsl:text> &gt; </xsl:text>
 
228
 
 
229
    <a href="{$path}/{$index-file}">
 
230
        <xsl:value-of select="$message[@id='version']"/>
 
231
    </a>
 
232
    </xsl:if>
 
233
 
 
234
    <xsl:if test="../modulesynopsis or ../directiveindex or ../quickreference">
 
235
    <xsl:text> &gt; </xsl:text>
 
236
 
 
237
    <a href="./{$index-file}">
 
238
        <xsl:value-of select="$message[@id='modules']"/>
 
239
    </a>
 
240
    </xsl:if>
 
241
 
 
242
    <xsl:if test="parentdocument/text()">
 
243
    <xsl:text> &gt; </xsl:text>
 
244
 
 
245
    <a href="{parentdocument/@href}">
 
246
        <xsl:call-template name="helper.uri.fix">
 
247
            <xsl:with-param name="uri" select="parentdocument/@href"/>
 
248
        </xsl:call-template>
 
249
        <xsl:value-of select="parentdocument"/>
 
250
    </a>
 
251
    </xsl:if>
 
252
</div> <!-- /path -->
 
253
</xsl:template>
 
254
<!-- /top -->
 
255
 
 
256
 
 
257
<!-- ==================================================================== -->
 
258
<!-- out of date                                                          -->
 
259
<!-- ==================================================================== -->
 
260
<xsl:template name="outofdate">
 
261
<xsl:if test="$metafile/variants/variant[.=$doclang]/@outdated = 'yes'">
 
262
    &lf;
 
263
    <div class="outofdate">
 
264
        <xsl:value-of select="$message[@id='outofdate']"/>
 
265
    </div>
 
266
</xsl:if>
 
267
</xsl:template>
 
268
 
 
269
 
 
270
<!-- ==================================================================== -->
 
271
<!-- page bottom                                                          -->
 
272
<!-- ==================================================================== -->
 
273
<xsl:template name="bottom">
 
274
<xsl:call-template name="langavail">
 
275
    <xsl:with-param name="position" select="'bottom'" />
 
276
</xsl:call-template>
 
277
 
 
278
<div id="footer">&lf;
 
279
    <p class="apache">
 
280
        <xsl:text>Copyright 2006 The Apache Software Foundation.</xsl:text><br />
 
281
        <xsl:value-of select="$message[@id='licensed']"/>
 
282
        <xsl:text> </xsl:text>
 
283
 
 
284
        <a href="http://www.apache.org/licenses/LICENSE-2.0">
 
285
            <xsl:if test="$ext-target">
 
286
                <xsl:attribute name="target">_blank</xsl:attribute>
 
287
            </xsl:if>
 
288
            <xsl:text>Apache License, Version 2.0</xsl:text>
 
289
        </a>
 
290
        <xsl:text>.</xsl:text>
 
291
    </p>&lf;
 
292
 
 
293
    <xsl:call-template name="super-menu"/>
 
294
 
 
295
</div> <!-- /footer -->
 
296
</xsl:template>
 
297
<!-- /bottom -->
 
298
 
 
299
 
 
300
<!-- ==================================================================== -->
 
301
<!-- build an "available languages" section                               -->
 
302
<!-- ==================================================================== -->
 
303
<xsl:template name="langavail">
 
304
<xsl:param name="position" select="'top'" />
 
305
 
 
306
<xsl:if test="not($is-chm or $is-zip)">
 
307
<div class="{$position}lang">&lf;
 
308
    <p>
 
309
        <span>
 
310
            <xsl:value-of select="$message[@id='langavail']" />
 
311
            <xsl:text>: </xsl:text>
 
312
        </span>
 
313
 
 
314
        <xsl:for-each select="$metafile/variants/variant">
 
315
        <xsl:sort select="." />
 
316
 
 
317
            <a href="{$path}/{.}{$metafile/path}{$metafile/basename}.html">
 
318
                <xsl:if test="$metafile/basename = 'index'">
 
319
                    <xsl:attribute name="href">
 
320
                        <xsl:value-of
 
321
                            select="concat($path, '/', ., $metafile/path)" />
 
322
                    </xsl:attribute>
 
323
                </xsl:if>
 
324
                <xsl:if test="$doclang != .">
 
325
                    <xsl:attribute name="hreflang">
 
326
                        <xsl:value-of select="." />
 
327
                    </xsl:attribute>
 
328
                    <xsl:attribute name="rel">alternate</xsl:attribute>
 
329
                </xsl:if>
 
330
                <xsl:attribute name="title">
 
331
                    <xsl:value-of select="document(concat('../lang/', .,
 
332
                                                   '.xml'))
 
333
                                          /language/messages/message
 
334
                                          [@id='nativename']" />
 
335
                </xsl:attribute>
 
336
 
 
337
                &nbsp;
 
338
                <xsl:value-of select="." />
 
339
                &nbsp;
 
340
            </a>
 
341
            <xsl:if test="position() != last()">
 
342
                <xsl:text> |&#xA;</xsl:text>
 
343
            </xsl:if>
 
344
        </xsl:for-each>
 
345
    </p>&lf;
 
346
</div> <!-- /.{$position}lang -->
 
347
</xsl:if>
 
348
 
 
349
<xsl:if test="$position = 'top'">
 
350
    <xsl:call-template name="outofdate" />
 
351
</xsl:if>
 
352
 
 
353
</xsl:template>
 
354
<!-- /langavail -->
 
355
 
 
356
 
 
357
<!-- ==================================================================== -->
 
358
<!-- Process a documentation section                                      -->
 
359
<!-- ==================================================================== -->
 
360
<xsl:template match="section">
 
361
<xsl:call-template name="toplink" />&lf;
 
362
<div class="section">&lf;
 
363
 
 
364
    <!-- Section heading -->
 
365
    <h2>
 
366
        <xsl:choose>
 
367
        <xsl:when test="@id">
 
368
          <a id="{@id}" name="{@id}">
 
369
              <xsl:apply-templates select="title" mode="print" />
 
370
          </a>
 
371
        </xsl:when>
 
372
 
 
373
        <xsl:otherwise>
 
374
            <xsl:apply-templates select="title" mode="print" />
 
375
        </xsl:otherwise>
 
376
        </xsl:choose>
 
377
    </h2>
 
378
 
 
379
    <!-- Section body -->
 
380
    <xsl:apply-templates />
 
381
</div> <!-- /.section -->
 
382
</xsl:template>
 
383
<!-- /section -->
 
384
 
 
385
 
 
386
<!-- ==================================================================== -->
 
387
<!-- handle subsections (lower level headings)                            -->
 
388
<!-- ==================================================================== -->
 
389
<xsl:template match="section/section">
 
390
<!-- Section heading -->
 
391
<h3>
 
392
    <xsl:choose>
 
393
    <xsl:when test="@id">
 
394
        <a id="{@id}" name="{@id}">
 
395
            <xsl:apply-templates select="title" mode="print" />
 
396
        </a>
 
397
    </xsl:when>
 
398
 
 
399
    <xsl:otherwise>
 
400
        <xsl:apply-templates select="title" mode="print" />
 
401
    </xsl:otherwise>
 
402
    </xsl:choose>
 
403
</h3>
 
404
 
 
405
<!-- Section body -->
 
406
<xsl:apply-templates />
 
407
</xsl:template>
 
408
<!-- /section/section -->
 
409
 
 
410
 
 
411
<!-- ==================================================================== -->
 
412
<!-- handle subsubsections (h4)                                           -->
 
413
<!-- ==================================================================== -->
 
414
<xsl:template match="section/section/section">
 
415
<!-- Section heading -->
 
416
<h4>
 
417
    <xsl:choose>
 
418
    <xsl:when test="@id">
 
419
        <a id="{@id}" name="{@id}">
 
420
            <xsl:apply-templates select="title" mode="print" />
 
421
        </a>
 
422
    </xsl:when>
 
423
 
 
424
    <xsl:otherwise>
 
425
        <xsl:apply-templates select="title" mode="print" />
 
426
    </xsl:otherwise>
 
427
    </xsl:choose>
 
428
</h4>
 
429
 
 
430
<!-- Section body -->
 
431
<xsl:apply-templates/>
 
432
 
 
433
</xsl:template>
 
434
<!-- /section/section/section -->
 
435
 
 
436
 
 
437
<!-- ==================================================================== -->
 
438
<!-- section nesting > h4 is not supported for now                        -->
 
439
<!-- ==================================================================== -->
 
440
<xsl:template match="section/section/section/section">
 
441
<xsl:message terminate="yes">
 
442
    <xsl:text>FATAL: exceeding maximum section nesting level.</xsl:text>
 
443
    &lf;&lf;
 
444
    <xsl:text>Perhaps you should consider to split your document into</xsl:text>
 
445
    &lf;
 
446
    <xsl:text>several ones...</xsl:text>
 
447
    &lf;
 
448
</xsl:message>
 
449
</xsl:template>
 
450
<!-- /section/section/section/section -->
 
451
 
 
452
 
 
453
<!-- ==================================================================== -->
 
454
<!-- (sub)section titles                                                  -->
 
455
<!-- ==================================================================== -->
 
456
<xsl:template match="section/title" mode="print">
 
457
<xsl:apply-templates/>
 
458
</xsl:template>
 
459
<xsl:template match="section/title" />
 
460
<!-- /section/title -->
 
461
 
 
462
 
 
463
<!-- ==================================================================== -->
 
464
<!-- generate section index                                               -->
 
465
<!-- ==================================================================== -->
 
466
<xsl:template match="section" mode="index">
 
467
<li>
 
468
    <img src="{$path}/images/down.gif" alt="" />
 
469
    <xsl:text> </xsl:text>
 
470
    <xsl:choose>
 
471
    <xsl:when test="@id">
 
472
        <a href="#{@id}">
 
473
            <xsl:apply-templates select="title" mode="print" />
 
474
        </a>
 
475
    </xsl:when>
 
476
    <xsl:otherwise>
 
477
        <xsl:apply-templates select="title" mode="print" />
 
478
    </xsl:otherwise>
 
479
    </xsl:choose>
 
480
</li>&lf;
 
481
</xsl:template>
 
482
<!-- /section index -->
 
483
 
 
484
 
 
485
<!-- ==================================================================== -->
 
486
<!-- docs super menu                                                      -->
 
487
<!-- ==================================================================== -->
 
488
<xsl:template name="super-menu">
 
489
<p class="menu">
 
490
    <a href="{$path}/mod/{$index-file}">
 
491
        <xsl:value-of select="$message[@id='modules']" />
 
492
    </a>
 
493
 
 
494
    <xsl:text> | </xsl:text>
 
495
 
 
496
    <a href="{$path}/mod/directives.html">
 
497
        <xsl:value-of select="$message[@id='directives']" />
 
498
    </a>
 
499
 
 
500
    <xsl:text> | </xsl:text>
 
501
 
 
502
    <a href="{$path}/faq/{$index-file}">
 
503
        <xsl:value-of select="$message[@id='faq']" />
 
504
    </a>
 
505
 
 
506
    <xsl:text> | </xsl:text>
 
507
 
 
508
    <a href="{$path}/glossary.html">
 
509
        <xsl:value-of select="$message[@id='glossary']" />
 
510
    </a>
 
511
 
 
512
    <xsl:text> | </xsl:text>
 
513
 
 
514
    <a href="{$path}/sitemap.html">
 
515
        <xsl:value-of select="$message[@id='sitemap']" />
 
516
    </a>
 
517
</p>
 
518
</xsl:template>
 
519
<!-- /super-menu -->
 
520
 
 
521
 
 
522
<!-- ==================================================================== -->
 
523
<!-- <example>                                                            -->
 
524
<!-- iterate over *all* nodes; bare text and other inline stuff is        -->
 
525
<!-- wrapped into <p><code>, block level elements (defined in             -->
 
526
<!-- $blockelements) are applied "as is"                                  -->
 
527
<!-- ==================================================================== -->
 
528
<xsl:variable name="blocks"
 
529
            select="concat(' ', normalize-space($blockelements), ' ')" />
 
530
 
 
531
<xsl:template match="example">
 
532
<div class="example">
 
533
    <xsl:apply-templates select="title" mode="print" />
 
534
 
 
535
    <xsl:for-each select="./node()">
 
536
        <xsl:variable name="is-block-node"
 
537
                    select="boolean(contains($blocks,
 
538
                                             concat(' ', local-name(), ' ')))"/>
 
539
        <!-- bb = (number of) blocks nodes before (the current) -->
 
540
        <xsl:variable name="bb"
 
541
                    select="count(preceding-sibling::*[
 
542
                                contains($blocks,
 
543
                                         concat(' ', local-name(), ' '))])" />
 
544
 
 
545
        <xsl:if test="$is-block-node or position()=last()">
 
546
            <xsl:variable name="content">
 
547
                <!-- phew. short explanation, what happens here:      -->
 
548
                <!-- We want to get the inline stuff between the last -->
 
549
                <!-- block node and the current node.                 -->
 
550
                <!-- So filter all previous nodes for the condition   -->
 
551
                <!-- that the number of block nodes of all of *their* -->
 
552
                <!-- previous nodes is >= $bb. Hope that helps ;-)    -->
 
553
                <xsl:apply-templates
 
554
                    select="preceding-sibling::node()[
 
555
                                count(preceding-sibling::*[
 
556
                                    contains($blocks,
 
557
                                             concat(' ', local-name(), ' '))])
 
558
                                &gt;= $bb]" />
 
559
 
 
560
                <xsl:apply-templates
 
561
                    select="self::node()[not($is-block-node)]" />
 
562
            </xsl:variable>
 
563
 
 
564
            <!-- apply bare text only, if it's not only \s or empty -->
 
565
            <xsl:if test="not(normalize-space($content) = '')">
 
566
                <p><code>
 
567
                    <!-- same as $content above. xsl:copy-of seems to make -->
 
568
                    <!-- thread problems with xalan-j ... -->
 
569
                    <xsl:apply-templates
 
570
                        select="preceding-sibling::node()[
 
571
                                    count(preceding-sibling::*[
 
572
                                        contains($blocks,
 
573
                                                 concat(' ', local-name(),
 
574
                                                        ' '))])
 
575
                                    &gt;= $bb]" />
 
576
 
 
577
                    <xsl:apply-templates
 
578
                        select="self::node()[not($is-block-node)]" />
 
579
                </code></p>
 
580
            </xsl:if>
 
581
 
 
582
            <xsl:apply-templates select="self::node()[$is-block-node]" />
 
583
        </xsl:if>
 
584
    </xsl:for-each>
 
585
    <!-- /node() -->
 
586
</div> <!-- /.example -->
 
587
</xsl:template>
 
588
<!-- /example -->
 
589
 
 
590
 
 
591
<!-- ==================================================================== -->
 
592
<!-- example/title                                                        -->
 
593
<!-- ==================================================================== -->
 
594
<xsl:template match="example/title" mode="print">
 
595
<h3>
 
596
    <xsl:apply-templates/>
 
597
</h3>
 
598
</xsl:template>
 
599
<xsl:template match="example/title" />
 
600
<!-- /example/title -->
 
601
 
 
602
 
 
603
<!-- ==================================================================== -->
 
604
<!-- indentations                                                         -->
 
605
<!-- ==================================================================== -->
 
606
<xsl:template match="indent">
 
607
<span class="indent">
 
608
    <xsl:apply-templates/>
 
609
</span>
 
610
</xsl:template>
 
611
<!-- /indent -->
 
612
 
 
613
 
 
614
<!-- ==================================================================== -->
 
615
<!-- <note>                                                               -->
 
616
<!-- ==================================================================== -->
 
617
<xsl:template match="note">
 
618
<div class="note">
 
619
    <xsl:if test="@type='warning'">
 
620
        <xsl:attribute name="class">warning</xsl:attribute>
 
621
    </xsl:if>
 
622
 
 
623
    <xsl:apply-templates/>
 
624
</div>
 
625
</xsl:template>
 
626
<!-- /note -->
 
627
 
 
628
 
 
629
<!-- ==================================================================== -->
 
630
<!-- <note><title>                                                        -->
 
631
<!-- ==================================================================== -->
 
632
<xsl:template match="note/title">
 
633
<h3>
 
634
    <xsl:apply-templates/>
 
635
</h3>
 
636
</xsl:template>
 
637
<!-- /note/title -->
 
638
 
 
639
 
 
640
<!-- ==================================================================== -->
 
641
<!-- <directive>                                                          -->
 
642
<!-- Inserts link to another directive, which might be in another module. -->
 
643
<!-- References are converted into lower case.                            -->
 
644
<!-- ==================================================================== -->
 
645
<xsl:template match="directive" name="directive">
 
646
<code class="directive">
 
647
    <xsl:choose>
 
648
    <xsl:when test="@module">
 
649
        <xsl:variable name="lowerdirective"
 
650
            select="translate(., $uppercase, $lowercase)" />
 
651
 
 
652
        <xsl:choose>
 
653
        <xsl:when test="$in-modulesynopsis and @module = /modulesynopsis/name">
 
654
            <a href="#{$lowerdirective}">
 
655
                <xsl:if test="@type='section'">&lt;</xsl:if>
 
656
                <xsl:value-of select="."/>
 
657
                <xsl:if test="@type='section'">&gt;</xsl:if>
 
658
            </a>
 
659
        </xsl:when>
 
660
        <xsl:otherwise>
 
661
            <a href="{$path}/mod/{@module}.html#{$lowerdirective}">
 
662
                <xsl:if test="@type='section'">&lt;</xsl:if>
 
663
                <xsl:value-of select="."/>
 
664
                <xsl:if test="@type='section'">&gt;</xsl:if>
 
665
            </a>
 
666
        </xsl:otherwise>
 
667
        </xsl:choose>
 
668
    </xsl:when>
 
669
 
 
670
    <xsl:otherwise>
 
671
        <xsl:if test="@type='section'">&lt;</xsl:if>
 
672
        <xsl:value-of select="."/>
 
673
        <xsl:if test="@type='section'">&gt;</xsl:if>
 
674
    </xsl:otherwise>
 
675
    </xsl:choose>
 
676
</code>
 
677
</xsl:template>
 
678
<!-- /directive -->
 
679
 
 
680
 
 
681
<!-- ==================================================================== -->
 
682
<!-- <module>                                                             -->
 
683
<!-- Inserts a link to refereed module                                    -->
 
684
<!-- ==================================================================== -->
 
685
<xsl:template match="module" name="module">
 
686
<code class="module">
 
687
    <a href="{$path}/mod/{.}.html">
 
688
        <xsl:value-of select="."/>
 
689
    </a>
 
690
</code>
 
691
</xsl:template>
 
692
<!-- /module -->
 
693
 
 
694
 
 
695
<!-- ==================================================================== -->
 
696
<!-- <program>                                                            -->
 
697
<!-- Inserts a link to referred program                                   -->
 
698
<!-- ==================================================================== -->
 
699
<xsl:template match="program">
 
700
<code class="program">
 
701
    <a href="{$path}/programs/{normalize-space(.)}.html">
 
702
        <xsl:value-of select="normalize-space(.)" />
 
703
    </a>
 
704
</code>
 
705
</xsl:template>
 
706
<!-- /program -->
 
707
 
 
708
 
 
709
<!-- ==================================================================== -->
 
710
<!-- <related>                                                            -->
 
711
<!-- ==================================================================== -->
 
712
<xsl:template match="related">
 
713
<table class="related">
 
714
<tr>
 
715
    <th>
 
716
        <xsl:value-of select="$message[@id='relatedmodules']" />
 
717
    </th>
 
718
    <th>
 
719
        <xsl:value-of select="$message[@id='relateddirectives']" />
 
720
    </th>
 
721
</tr>
 
722
<tr>
 
723
    <td>
 
724
        <xsl:if test="count(modulelist/*) &gt; 0">
 
725
            <ul>
 
726
                <xsl:apply-templates select="modulelist" />
 
727
            </ul>
 
728
        </xsl:if>
 
729
    </td>
 
730
    <td>
 
731
        <xsl:if test="count(directivelist/*) &gt; 0">
 
732
            <ul>
 
733
                <xsl:apply-templates select="directivelist"/>
 
734
            </ul>
 
735
        </xsl:if>
 
736
    </td>
 
737
</tr>
 
738
</table>
 
739
</xsl:template>
 
740
<!-- /related -->
 
741
 
 
742
<!-- ==================================================================== -->
 
743
<!-- related/modulelist                                                   -->
 
744
<!-- ==================================================================== -->
 
745
<xsl:template match="related/modulelist">
 
746
<xsl:for-each select="module">
 
747
    <li>
 
748
        <xsl:call-template name="module"/>
 
749
    </li>
 
750
</xsl:for-each>
 
751
</xsl:template>
 
752
<!-- /related/modulelist -->
 
753
 
 
754
 
 
755
<!-- ==================================================================== -->
 
756
<!-- related/directivelist                                                -->
 
757
<!-- ==================================================================== -->
 
758
<xsl:template match="related/directivelist">
 
759
<xsl:for-each select="directive">
 
760
    <li>
 
761
        <xsl:call-template name="directive"/>
 
762
    </li>
 
763
</xsl:for-each>
 
764
</xsl:template>
 
765
<!-- /related/directivelist -->
 
766
 
 
767
 
 
768
<!-- ==================================================================== -->
 
769
<!-- <table>                                                              -->
 
770
<!-- ==================================================================== -->
 
771
<xsl:template match="table">
 
772
<table>
 
773
    <!-- existing border attribute will result in <table class="bordered"> -->
 
774
    <xsl:if test="@border">
 
775
        <xsl:attribute name="class">bordered</xsl:attribute>
 
776
    </xsl:if>
 
777
 
 
778
    <xsl:choose>
 
779
    <xsl:when test="@style = 'zebra'">
 
780
        <xsl:apply-templates select="tr" mode="zebra-table" />
 
781
    </xsl:when>
 
782
    <xsl:when test="@style = 'data'">
 
783
        <xsl:apply-templates select="tr" mode="data-table" />
 
784
    </xsl:when>
 
785
    <xsl:otherwise>
 
786
        <xsl:apply-templates />
 
787
    </xsl:otherwise>
 
788
    </xsl:choose>
 
789
</table>
 
790
</xsl:template>
 
791
<!-- /table -->
 
792
 
 
793
<!-- data-table -->
 
794
<xsl:template match="tr" mode="data-table">
 
795
<!-- style="data": fixed font, padding-left and right alignment for <td>s -->
 
796
<xsl:variable name="cross-table" select="boolean(
 
797
    preceding-sibling::tr/th[1]|following-sibling::tr/th[1])" />
 
798
 
 
799
<tr>
 
800
    <xsl:for-each select="node()">
 
801
        <xsl:choose>
 
802
        <xsl:when test="local-name() = 'td'">
 
803
            <td class="data">
 
804
                <xsl:apply-templates select="*|@*|text()" />
 
805
            </td>
 
806
        </xsl:when>
 
807
        <xsl:when test="local-name() = 'th' and
 
808
                        (not($cross-table) or
 
809
                         count(preceding-sibling::*) &gt; 0)">
 
810
            <th class="data">
 
811
                <xsl:apply-templates select="*|@*|text()" />
 
812
            </th>
 
813
        </xsl:when>
 
814
        <xsl:otherwise>
 
815
            <xsl:apply-templates select="self::node()" />
 
816
        </xsl:otherwise>
 
817
        </xsl:choose>
 
818
    </xsl:for-each>
 
819
</tr>&lf;
 
820
</xsl:template>
 
821
 
 
822
 
 
823
<!-- zebra-table -->
 
824
<xsl:template match="tr" mode="zebra-table">
 
825
<!-- style="zebra": alternating colors per row, i.e. every second row -->
 
826
<!--                gets a class="odd". Header lines (no <td>) get a  -->
 
827
<!--                class="header". These lines will be excluded from -->
 
828
<!--                the "odd" line count. That way header lines act   -->
 
829
<!--                interjectional, which creates a better visual and -->
 
830
<!--                psychological effect.                             -->
 
831
<tr>
 
832
    <xsl:choose>
 
833
    <xsl:when test="count(td) = 0">
 
834
        <xsl:attribute name="class">header</xsl:attribute>
 
835
    </xsl:when>
 
836
 
 
837
    <xsl:when test="position() mod 2 = (count(preceding-sibling::tr[count(td) = 0]) mod 2)">
 
838
        <xsl:attribute name="class">odd</xsl:attribute>
 
839
    </xsl:when>
 
840
    </xsl:choose>
 
841
 
 
842
    <xsl:apply-templates />
 
843
</tr>&lf;
 
844
</xsl:template>
 
845
<!-- /zebra-table -->
 
846
 
 
847
 
 
848
<!-- ==================================================================== -->
 
849
<!-- <ol>                                                                 -->
 
850
<!-- ==================================================================== -->
 
851
<xsl:template match="ol">
 
852
<ol>
 
853
    <!-- A. B. C. D. (list-style-type="upper-alpha") -->
 
854
    <xsl:choose>
 
855
    <xsl:when test="@type = 'A'">
 
856
        <xsl:attribute name="class">up-A</xsl:attribute>
 
857
    </xsl:when>
 
858
    <xsl:when test="@type = 'a'">
 
859
        <xsl:attribute name="class">lo-A</xsl:attribute>
 
860
    </xsl:when>
 
861
    </xsl:choose>
 
862
 
 
863
    <xsl:apply-templates/>
 
864
</ol>
 
865
</xsl:template>
 
866
<!-- /ol -->
 
867
 
 
868
 
 
869
<!-- ==================================================================== -->
 
870
<!-- diverse elements                                                     -->
 
871
<!-- Passes through content                                               -->
 
872
<!-- ==================================================================== -->
 
873
<xsl:template match="summary|description|usage|syntax|default">
 
874
<xsl:apply-templates/>
 
875
</xsl:template>
 
876
<!-- /diverse -->
 
877
 
 
878
 
 
879
<!-- ==================================================================== -->
 
880
<!-- <a>                                                                  -->
 
881
<!-- ==================================================================== -->
 
882
<xsl:template match="a">
 
883
<xsl:choose>
 
884
<xsl:when test="not(@href)">
 
885
    <xsl:copy>
 
886
        <xsl:apply-templates select="@*|*|text()"/>
 
887
    </xsl:copy>
 
888
</xsl:when>
 
889
<xsl:otherwise>
 
890
    <a href="@href">
 
891
        <xsl:apply-templates select="@*"/>
 
892
        <xsl:call-template name="helper.uri.fix">
 
893
            <xsl:with-param name="uri" select="@href"/>
 
894
        </xsl:call-template>
 
895
 
 
896
        <xsl:apply-templates select="*|text()"/>
 
897
    </a>
 
898
</xsl:otherwise>
 
899
</xsl:choose>
 
900
</xsl:template> 
 
901
<!-- /a -->
 
902
 
 
903
 
 
904
<!-- ==================================================================== -->
 
905
<!-- toplink                                                              -->
 
906
<!-- ==================================================================== -->
 
907
<xsl:template name="toplink">
 
908
<div class="top">
 
909
    <a href="#page-header"><img src="{$path}/images/up.gif" alt="top" /></a>
 
910
</div>
 
911
</xsl:template>
 
912
<!-- /toplink -->
 
913
 
 
914
 
 
915
<!-- ==================================================================== -->
 
916
<!-- <transnote>                                                          -->
 
917
<!-- translator's notes are displayed in a different color                -->
 
918
<!-- ==================================================================== -->
 
919
<xsl:template match="transnote">
 
920
<span class="transnote">
 
921
    <xsl:text>(</xsl:text>
 
922
    <em>
 
923
        <xsl:value-of select="$message[@id='transnote']" />
 
924
    </em>
 
925
    <xsl:text> </xsl:text>
 
926
    <xsl:apply-templates />
 
927
    <xsl:text>)</xsl:text>
 
928
</span>
 
929
</xsl:template>
 
930
<!-- /transnote -->
 
931
 
 
932
<!-- ==================================================================== -->
 
933
<!-- <phonetic>                                                           -->
 
934
<!-- phonetics are enclosed in  square brackets and displayed in a        -->
 
935
<!-- different color                                                      -->
 
936
<!-- ==================================================================== -->
 
937
<xsl:template match="phonetic">
 
938
<span class="phonetic">
 
939
    <xsl:text>[</xsl:text>
 
940
    <xsl:apply-templates />
 
941
    <xsl:text>]</xsl:text>
 
942
</span>
 
943
</xsl:template>
 
944
<!-- /phonetic -->
 
945
 
 
946
 
 
947
<!-- ==================================================================== -->
 
948
<!-- <glossary>                                                           -->
 
949
<!-- link to a glossary anchor                                            -->
 
950
<!-- ==================================================================== -->
 
951
<xsl:template match="glossary">
 
952
  <xsl:variable name="glosslink">
 
953
    <xsl:choose>
 
954
    <xsl:when test="@ref">
 
955
      <xsl:value-of select="@ref"/>
 
956
    </xsl:when>
 
957
    <xsl:otherwise>
 
958
      <xsl:value-of select="translate(., $uppercase, $lowercase)"/>
 
959
    </xsl:otherwise>
 
960
    </xsl:choose>
 
961
  </xsl:variable>
 
962
 
 
963
  <a href="{$path}/glossary.html#{$glosslink}" class="glossarylink">
 
964
     <xsl:attribute name="title">
 
965
        <xsl:value-of select="$message[@id='glossarylink']" />
 
966
     </xsl:attribute>
 
967
     <xsl:apply-templates />
 
968
  </a>
 
969
</xsl:template>
 
970
<!-- /glossary -->
 
971
 
 
972
<!-- ==================================================================== -->
 
973
<!-- Filter &#160; in text() nodes.                                       -->
 
974
<!-- In some environments this character won't be transformed correctly,  -->
 
975
<!-- so we just write it explicitely as "&nbsp;" into the output.         -->
 
976
<!-- ==================================================================== -->
 
977
<xsl:template match="text()" name="filter.nbsp">
 
978
<xsl:param name="text" select="." />
 
979
 
 
980
<xsl:choose>
 
981
<xsl:when test="contains($text, '&#160;')">
 
982
    <xsl:value-of select="substring-before($text, '&#160;')" />
 
983
    &nbsp;
 
984
    <xsl:call-template name="filter.nbsp">
 
985
        <xsl:with-param name="text" select="substring-after($text, '&#160;')" />
 
986
    </xsl:call-template>
 
987
</xsl:when>
 
988
<xsl:otherwise>
 
989
    <xsl:value-of select="$text" />
 
990
</xsl:otherwise>
 
991
</xsl:choose>
 
992
</xsl:template>
 
993
<!-- /filter.nbsp -->
 
994
 
 
995
 
 
996
<!-- ==================================================================== -->
 
997
<!-- Process everything else by just passing it through                   -->
 
998
<!-- ==================================================================== -->
 
999
<xsl:template match="*">
 
1000
<xsl:message terminate="yes">
 
1001
    <xsl:text>Unknown element: </xsl:text>
 
1002
    <xsl:value-of select="local-name()" />&lf;
 
1003
    <xsl:text>Is the document valid (try `build validate-xml`)?</xsl:text>
 
1004
</xsl:message>
 
1005
</xsl:template>
 
1006
<xsl:template match="@*">
 
1007
<xsl:copy>
 
1008
    <xsl:apply-templates select="*|@*|text()" />
 
1009
</xsl:copy>
 
1010
</xsl:template>
 
1011
<xsl:template match="br"><br /></xsl:template>
 
1012
<xsl:template match="tr"><tr><xsl:apply-templates select="*|@*|text()" /></tr></xsl:template>
 
1013
<xsl:template match="th"><th><xsl:apply-templates select="*|@*|text()" /></th></xsl:template>
 
1014
<xsl:template match="td"><td><xsl:apply-templates select="*|@*|text()" /></td></xsl:template>
 
1015
<xsl:template match="p"><p><xsl:apply-templates select="*|@*|text()" /></p></xsl:template>
 
1016
<xsl:template match="ul"><ul><xsl:apply-templates select="*|@*|text()" /></ul></xsl:template>
 
1017
<xsl:template match="li"><li><xsl:apply-templates select="*|@*|text()" /></li></xsl:template>
 
1018
<xsl:template match="dl"><dl><xsl:apply-templates select="*|@*|text()" /></dl></xsl:template>
 
1019
<xsl:template match="dt"><dt><xsl:apply-templates select="*|@*|text()" /></dt></xsl:template>
 
1020
<xsl:template match="dd"><dd><xsl:apply-templates select="*|@*|text()" /></dd></xsl:template>
 
1021
<xsl:template match="em"><em><xsl:apply-templates select="*|@*|text()" /></em></xsl:template>
 
1022
<xsl:template match="strong"><strong><xsl:apply-templates select="*|@*|text()" /></strong></xsl:template>
 
1023
<xsl:template match="pre"><pre><xsl:apply-templates select="*|@*|text()" /></pre></xsl:template>
 
1024
<xsl:template match="code"><code><xsl:apply-templates select="*|@*|text()" /></code></xsl:template>
 
1025
<xsl:template match="var"><var><xsl:apply-templates select="*|@*|text()" /></var></xsl:template>
 
1026
<xsl:template match="dfn"><dfn><xsl:apply-templates select="*|@*|text()" /></dfn></xsl:template>
 
1027
<xsl:template match="blockquote"><blockquote><xsl:apply-templates select="*|@*|text()" /></blockquote></xsl:template>
 
1028
<xsl:template match="q"><q><xsl:apply-templates select="*|@*|text()" /></q></xsl:template>
 
1029
<xsl:template match="cite"><cite><xsl:apply-templates select="*|@*|text()" /></cite></xsl:template>
 
1030
<xsl:template match="img"><img><xsl:apply-templates select="*|@*|text()" /></img></xsl:template>
 
1031
<!-- /pass through -->
 
1032
 
 
1033
 
 
1034
<!-- ==================================================================== -->
 
1035
<!-- create a letter bar                                                  -->
 
1036
<!-- ==================================================================== -->
 
1037
<xsl:template name="letter-bar">
 
1038
<xsl:param name="letters" />
 
1039
<xsl:param name="first" />
 
1040
 
 
1041
<xsl:if test="not($first)">
 
1042
    <xsl:text> | </xsl:text>
 
1043
</xsl:if>
 
1044
 
 
1045
<a href="#{substring($letters,1,1)}">
 
1046
    &nbsp;
 
1047
    <xsl:value-of select="substring($letters, 1, 1)" />
 
1048
    &nbsp;
 
1049
</a>
 
1050
 
 
1051
<xsl:if test="string-length($letters) &gt; 1">
 
1052
    <xsl:call-template name="letter-bar">
 
1053
        <xsl:with-param name="letters" select="substring($letters, 2)" />
 
1054
        <xsl:with-param name="first" select="false()" />
 
1055
    </xsl:call-template>
 
1056
</xsl:if>
 
1057
</xsl:template>
 
1058
<!-- /letter-bar -->
 
1059
 
 
1060
 
 
1061
<!-- ==================================================================== -->
 
1062
<!-- template(s) for collecting all start letters of directives           -->
 
1063
<!-- ==================================================================== -->
 
1064
<xsl:template name="directive-startletters">
 
1065
<xsl:param name="directives" />
 
1066
 
 
1067
<xsl:call-template name="_squeeze-letters">
 
1068
    <xsl:with-param name="lastletter" select="''" />
 
1069
    <xsl:with-param name="letters">
 
1070
        <xsl:for-each select="$directives">
 
1071
        <xsl:sort select="name"/>
 
1072
            <xsl:value-of
 
1073
                select="translate(substring(normalize-space(name), 1, 1),
 
1074
                                  $lowercase, $uppercase)" />
 
1075
        </xsl:for-each>
 
1076
    </xsl:with-param>
 
1077
</xsl:call-template>
 
1078
</xsl:template>
 
1079
<!-- /directive-startletters -->
 
1080
 
 
1081
 
 
1082
<!-- ==================================================================== -->
 
1083
<!-- squeeze subsequent letters in a string                               -->
 
1084
<!-- ==================================================================== -->
 
1085
<xsl:template name="_squeeze-letters">
 
1086
<xsl:param name="letters"/>
 
1087
<xsl:param name="lastletter"/>
 
1088
 
 
1089
<xsl:variable name="current" select="substring($letters, 1, 1)" />
 
1090
 
 
1091
<xsl:if test="not($lastletter = $current)">
 
1092
    <xsl:value-of select="$current" />
 
1093
</xsl:if>
 
1094
 
 
1095
<xsl:if test="string-length($letters) &gt; 1">
 
1096
    <xsl:call-template name="_squeeze-letters">
 
1097
        <xsl:with-param name="letters" select="substring($letters, 2)" />
 
1098
        <xsl:with-param name="lastletter" select="$current"/>
 
1099
    </xsl:call-template>
 
1100
</xsl:if>
 
1101
</xsl:template>
 
1102
<!-- /_squeeze-letters -->
 
1103
 
 
1104
 
 
1105
<!-- ==================================================================== -->
 
1106
<!-- fix href and target attribute of an element.                         -->
 
1107
<!-- ==================================================================== -->
 
1108
<xsl:template name="helper.uri.fix">
 
1109
<xsl:param name="uri"/>
 
1110
 
 
1111
<xsl:choose>
 
1112
<!-- lame is_absolute_uri test -->
 
1113
<xsl:when test="    contains($uri, ':')
 
1114
                and string-length(substring-before($uri, ':')) &lt; 7">
 
1115
    <xsl:if test="$ext-target">
 
1116
        <xsl:attribute name="target">_blank</xsl:attribute>
 
1117
    </xsl:if>
 
1118
</xsl:when>
 
1119
<xsl:otherwise>
 
1120
    <xsl:variable name="fragment">
 
1121
        <xsl:if test="contains($uri, '#')">
 
1122
            <xsl:value-of select="concat('#', substring-after($uri, '#'))"/>
 
1123
        </xsl:if>
 
1124
    </xsl:variable>
 
1125
    <xsl:variable name="absuri">
 
1126
        <xsl:choose>
 
1127
        <xsl:when test="contains($uri, '#')">
 
1128
            <xsl:value-of select="concat('#', substring-before($uri, '#'))"/>
 
1129
        </xsl:when>
 
1130
        <xsl:otherwise>
 
1131
            <xsl:value-of select="$uri"/>
 
1132
        </xsl:otherwise>
 
1133
        </xsl:choose>
 
1134
    </xsl:variable>
 
1135
        
 
1136
    <xsl:if test="substring($absuri, string-length($uri), 1) = '/'">
 
1137
        <xsl:attribute name="href">
 
1138
            <xsl:value-of select="concat($absuri, $index-file, $fragment)"/>
 
1139
        </xsl:attribute>
 
1140
    </xsl:if>
 
1141
</xsl:otherwise>
 
1142
</xsl:choose>
 
1143
</xsl:template>
 
1144
<!-- /helper.uri.fix -->
 
1145
 
 
1146
 
 
1147
<!-- ==================================================================== -->
 
1148
<!-- Ignore table hints used for latex                                    -->
 
1149
<!-- ==================================================================== -->
 
1150
<xsl:template match="columnspec">
 
1151
</xsl:template>
 
1152
 
 
1153
<xsl:template match="column">
 
1154
</xsl:template>
 
1155
 
 
1156
</xsl:stylesheet>