2 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
5 <!-- ********************************************************************
6 $Id: titlepage.xsl 8491 2009-07-19 10:02:57Z mzjn $
7 ********************************************************************
9 This file is part of the XSL DocBook Stylesheet distribution.
10 See ../README or http://docbook.sf.net/release/xsl/current/ for
11 copyright and other information.
13 ******************************************************************** -->
15 <!-- ==================================================================== -->
17 <xsl:attribute-set name="book.titlepage.recto.style"/>
18 <xsl:attribute-set name="book.titlepage.verso.style"/>
20 <xsl:attribute-set name="article.titlepage.recto.style"/>
21 <xsl:attribute-set name="article.titlepage.verso.style"/>
23 <xsl:attribute-set name="set.titlepage.recto.style"/>
24 <xsl:attribute-set name="set.titlepage.verso.style"/>
26 <xsl:attribute-set name="part.titlepage.recto.style"/>
27 <xsl:attribute-set name="part.titlepage.verso.style"/>
29 <xsl:attribute-set name="partintro.titlepage.recto.style"/>
30 <xsl:attribute-set name="partintro.titlepage.verso.style"/>
32 <xsl:attribute-set name="reference.titlepage.recto.style"/>
33 <xsl:attribute-set name="reference.titlepage.verso.style"/>
35 <xsl:attribute-set name="refentry.titlepage.recto.style"/>
36 <xsl:attribute-set name="refentry.titlepage.verso.style"/>
38 <xsl:attribute-set name="dedication.titlepage.recto.style"/>
39 <xsl:attribute-set name="dedication.titlepage.verso.style"/>
41 <xsl:attribute-set name="acknowledgements.titlepage.recto.style"/>
42 <xsl:attribute-set name="acknowledgements.titlepage.verso.style"/>
44 <xsl:attribute-set name="preface.titlepage.recto.style"/>
45 <xsl:attribute-set name="preface.titlepage.verso.style"/>
47 <xsl:attribute-set name="chapter.titlepage.recto.style"/>
48 <xsl:attribute-set name="chapter.titlepage.verso.style"/>
50 <xsl:attribute-set name="appendix.titlepage.recto.style"/>
51 <xsl:attribute-set name="appendix.titlepage.verso.style"/>
53 <xsl:attribute-set name="bibliography.titlepage.recto.style"/>
54 <xsl:attribute-set name="bibliography.titlepage.verso.style"/>
56 <xsl:attribute-set name="glossary.titlepage.recto.style"/>
57 <xsl:attribute-set name="glossary.titlepage.verso.style"/>
59 <xsl:attribute-set name="index.titlepage.recto.style"/>
60 <xsl:attribute-set name="index.titlepage.verso.style"/>
62 <xsl:attribute-set name="setindex.titlepage.recto.style"/>
63 <xsl:attribute-set name="setindex.titlepage.verso.style"/>
65 <xsl:attribute-set name="section.titlepage.recto.style"/>
66 <xsl:attribute-set name="section.titlepage.verso.style"/>
68 <xsl:attribute-set name="sect1.titlepage.recto.style"
69 use-attribute-sets="section.titlepage.recto.style"/>
70 <xsl:attribute-set name="sect1.titlepage.verso.style"
71 use-attribute-sets="section.titlepage.verso.style"/>
73 <xsl:attribute-set name="sect2.titlepage.recto.style"
74 use-attribute-sets="section.titlepage.recto.style"/>
75 <xsl:attribute-set name="sect2.titlepage.verso.style"
76 use-attribute-sets="section.titlepage.verso.style"/>
78 <xsl:attribute-set name="sect3.titlepage.recto.style"
79 use-attribute-sets="section.titlepage.recto.style"/>
80 <xsl:attribute-set name="sect3.titlepage.verso.style"
81 use-attribute-sets="section.titlepage.verso.style"/>
83 <xsl:attribute-set name="sect4.titlepage.recto.style"
84 use-attribute-sets="section.titlepage.recto.style"/>
85 <xsl:attribute-set name="sect4.titlepage.verso.style"
86 use-attribute-sets="section.titlepage.verso.style"/>
88 <xsl:attribute-set name="sect5.titlepage.recto.style"
89 use-attribute-sets="section.titlepage.recto.style"/>
90 <xsl:attribute-set name="sect5.titlepage.verso.style"
91 use-attribute-sets="section.titlepage.verso.style"/>
93 <xsl:attribute-set name="simplesect.titlepage.recto.style"
94 use-attribute-sets="section.titlepage.recto.style"/>
95 <xsl:attribute-set name="simplesect.titlepage.verso.style"
96 use-attribute-sets="section.titlepage.verso.style"/>
98 <xsl:attribute-set name="table.of.contents.titlepage.recto.style"/>
99 <xsl:attribute-set name="table.of.contents.titlepage.verso.style"/>
101 <xsl:attribute-set name="list.of.tables.titlepage.recto.style"/>
102 <xsl:attribute-set name="list.of.tables.contents.titlepage.verso.style"/>
104 <xsl:attribute-set name="list.of.figures.titlepage.recto.style"/>
105 <xsl:attribute-set name="list.of.figures.contents.titlepage.verso.style"/>
107 <xsl:attribute-set name="list.of.equations.titlepage.recto.style"/>
108 <xsl:attribute-set name="list.of.equations.contents.titlepage.verso.style"/>
110 <xsl:attribute-set name="list.of.examples.titlepage.recto.style"/>
111 <xsl:attribute-set name="list.of.examples.contents.titlepage.verso.style"/>
113 <xsl:attribute-set name="list.of.unknowns.titlepage.recto.style"/>
114 <xsl:attribute-set name="list.of.unknowns.contents.titlepage.verso.style"/>
116 <!-- ==================================================================== -->
118 <xsl:template match="*" mode="titlepage.mode">
119 <!-- if an element isn't found in this mode, try the default mode -->
120 <xsl:apply-templates select="."/>
123 <xsl:template match="abbrev" mode="titlepage.mode">
125 <xsl:apply-templates select="." mode="common.html.attributes"/>
126 <xsl:apply-templates mode="titlepage.mode"/>
131 <xsl:template match="abstract" mode="titlepage.mode">
133 <xsl:apply-templates select="." mode="common.html.attributes"/>
134 <xsl:call-template name="anchor"/>
135 <xsl:if test="$abstract.notitle.enabled = 0">
136 <xsl:call-template name="formal.object.heading">
137 <xsl:with-param name="title">
138 <xsl:apply-templates select="." mode="title.markup"/>
142 <xsl:apply-templates mode="titlepage.mode"/>
143 <xsl:call-template name="process.footnotes"/>
147 <xsl:template match="abstract/title" mode="titlepage.mode">
150 <xsl:template match="address" mode="titlepage.mode">
151 <xsl:param name="suppress-numbers" select="'0'"/>
153 <xsl:variable name="rtf">
154 <xsl:apply-templates mode="titlepage.mode"/>
158 <xsl:when test="$suppress-numbers = '0'
159 and @linenumbering = 'numbered'
160 and $use.extensions != '0'
161 and $linenumbering.extension != '0'">
163 <xsl:apply-templates select="." mode="common.html.attributes"/>
164 <xsl:call-template name="paragraph">
165 <xsl:with-param name="content">
166 <xsl:call-template name="number.rtf.lines">
167 <xsl:with-param name="rtf" select="$rtf"/>
176 <xsl:apply-templates select="." mode="common.html.attributes"/>
177 <xsl:call-template name="paragraph">
178 <xsl:with-param name="content">
179 <xsl:call-template name="make-verbatim">
180 <xsl:with-param name="rtf" select="$rtf"/>
189 <xsl:template match="affiliation" mode="titlepage.mode">
191 <xsl:apply-templates select="." mode="common.html.attributes"/>
192 <xsl:apply-templates mode="titlepage.mode"/>
196 <xsl:template match="artpagenums" mode="titlepage.mode">
198 <xsl:apply-templates select="." mode="common.html.attributes"/>
199 <xsl:apply-templates mode="titlepage.mode"/>
204 <xsl:template match="author|editor" mode="titlepage.mode">
205 <xsl:call-template name="credits.div"/>
208 <xsl:template name="credits.div">
210 <xsl:apply-templates select="." mode="common.html.attributes"/>
211 <xsl:if test="self::editor[position()=1] and not($editedby.enabled = 0)">
212 <h4 class="editedby"><xsl:call-template name="gentext.edited.by"/></h4>
215 <xsl:apply-templates select="." mode="common.html.attributes"/>
217 <xsl:when test="orgname">
218 <xsl:apply-templates/>
221 <xsl:call-template name="person.name"/>
225 <xsl:if test="not($contrib.inline.enabled = 0)">
226 <xsl:apply-templates mode="titlepage.mode" select="contrib"/>
228 <xsl:apply-templates mode="titlepage.mode" select="affiliation"/>
229 <xsl:apply-templates mode="titlepage.mode" select="email"/>
230 <xsl:if test="not($blurb.on.titlepage.enabled = 0)">
232 <xsl:when test="$contrib.inline.enabled = 0">
233 <xsl:apply-templates mode="titlepage.mode"
234 select="contrib|authorblurb|personblurb"/>
237 <xsl:apply-templates mode="titlepage.mode"
238 select="authorblurb|personblurb"/>
245 <xsl:template match="authorblurb|personblurb" mode="titlepage.mode">
247 <xsl:apply-templates select="." mode="common.html.attributes"/>
248 <xsl:apply-templates mode="titlepage.mode"/>
252 <xsl:template match="authorgroup" mode="titlepage.mode">
254 <xsl:apply-templates select="." mode="common.html.attributes"/>
255 <xsl:if test="parent::refentryinfo">
259 <xsl:call-template name="anchor"/>
260 <xsl:apply-templates mode="titlepage.mode"/>
264 <xsl:template match="authorinitials" mode="titlepage.mode">
266 <xsl:apply-templates select="." mode="common.html.attributes"/>
267 <xsl:apply-templates mode="titlepage.mode"/>
272 <xsl:template match="bibliomisc" mode="titlepage.mode">
273 <xsl:apply-templates mode="titlepage.mode"/>
276 <xsl:template match="bibliomset" mode="titlepage.mode">
277 <xsl:apply-templates mode="titlepage.mode"/>
280 <xsl:template match="collab" mode="titlepage.mode">
282 <xsl:apply-templates select="." mode="common.html.attributes"/>
283 <xsl:apply-templates mode="titlepage.mode"/>
288 <xsl:template match="collabname" mode="titlepage.mode">
290 <xsl:apply-templates select="." mode="common.html.attributes"/>
291 <xsl:apply-templates mode="titlepage.mode"/>
295 <xsl:template match="confgroup" mode="titlepage.mode">
297 <xsl:apply-templates select="." mode="common.html.attributes"/>
298 <xsl:apply-templates mode="titlepage.mode"/>
302 <xsl:template match="confdates" mode="titlepage.mode">
304 <xsl:apply-templates select="." mode="common.html.attributes"/>
305 <xsl:apply-templates mode="titlepage.mode"/>
310 <xsl:template match="confsponsor" mode="titlepage.mode">
312 <xsl:apply-templates select="." mode="common.html.attributes"/>
313 <xsl:apply-templates mode="titlepage.mode"/>
318 <xsl:template match="conftitle" mode="titlepage.mode">
320 <xsl:apply-templates select="." mode="common.html.attributes"/>
321 <xsl:apply-templates mode="titlepage.mode"/>
326 <xsl:template match="confnum" mode="titlepage.mode">
330 <xsl:template match="contractnum" mode="titlepage.mode">
332 <xsl:apply-templates select="." mode="common.html.attributes"/>
333 <xsl:apply-templates mode="titlepage.mode"/>
338 <xsl:template match="contractsponsor" mode="titlepage.mode">
340 <xsl:apply-templates select="." mode="common.html.attributes"/>
341 <xsl:apply-templates mode="titlepage.mode"/>
346 <xsl:template match="contrib" mode="titlepage.mode">
348 <xsl:when test="not($contrib.inline.enabled = 0)">
350 <xsl:apply-templates select="." mode="common.html.attributes"/>
351 <xsl:apply-templates mode="titlepage.mode"/>
352 </span><xsl:text> </xsl:text>
356 <xsl:apply-templates select="." mode="common.html.attributes"/>
357 <p><xsl:apply-templates mode="titlepage.mode"/></p>
363 <xsl:template match="copyright" mode="titlepage.mode">
365 <xsl:if test="generate-id() = generate-id(//refentryinfo/copyright[1])
366 and ($stylesheet.result.type = 'html' or $stylesheet.result.type = 'xhtml')">
371 <xsl:apply-templates select="." mode="common.html.attributes"/>
372 <xsl:call-template name="gentext">
373 <xsl:with-param name="key" select="'Copyright'"/>
375 <xsl:call-template name="gentext.space"/>
376 <xsl:call-template name="dingbat">
377 <xsl:with-param name="dingbat">copyright</xsl:with-param>
379 <xsl:call-template name="gentext.space"/>
380 <xsl:call-template name="copyright.years">
381 <xsl:with-param name="years" select="year"/>
382 <xsl:with-param name="print.ranges" select="$make.year.ranges"/>
383 <xsl:with-param name="single.year.ranges"
384 select="$make.single.year.ranges"/>
386 <xsl:call-template name="gentext.space"/>
387 <xsl:apply-templates select="holder" mode="titlepage.mode"/>
391 <xsl:template match="year" mode="titlepage.mode">
393 <xsl:when test="$show.revisionflag != 0 and @revisionflag">
394 <span class="{@revisionflag}">
395 <xsl:apply-templates mode="titlepage.mode"/>
399 <xsl:apply-templates mode="titlepage.mode"/>
404 <xsl:template match="holder" mode="titlepage.mode">
406 <xsl:when test="$show.revisionflag != 0 and @revisionflag">
407 <span class="{@revisionflag}">
408 <xsl:apply-templates mode="titlepage.mode"/>
412 <xsl:apply-templates mode="titlepage.mode"/>
415 <xsl:if test="position() < last()">
416 <xsl:text>, </xsl:text>
420 <xsl:template match="corpauthor" mode="titlepage.mode">
422 <xsl:apply-templates select="." mode="common.html.attributes"/>
423 <xsl:apply-templates mode="titlepage.mode"/>
427 <xsl:template match="corpcredit" mode="titlepage.mode">
429 <xsl:apply-templates select="." mode="common.html.attributes"/>
430 <xsl:apply-templates mode="titlepage.mode"/>
435 <xsl:template match="corpname" mode="titlepage.mode">
437 <xsl:apply-templates select="." mode="common.html.attributes"/>
438 <xsl:apply-templates mode="titlepage.mode"/>
443 <xsl:template match="date" mode="titlepage.mode">
445 <xsl:apply-templates select="." mode="common.html.attributes"/>
446 <xsl:apply-templates mode="titlepage.mode"/>
451 <xsl:template match="edition" mode="titlepage.mode">
453 <xsl:apply-templates select="." mode="common.html.attributes"/>
454 <xsl:apply-templates mode="titlepage.mode"/>
455 <xsl:call-template name="gentext.space"/>
456 <xsl:call-template name="gentext">
457 <xsl:with-param name="key" select="'Edition'"/>
462 <xsl:template match="email" mode="titlepage.mode">
463 <!-- use the normal e-mail handling code -->
464 <xsl:apply-templates select="."/>
467 <xsl:template match="firstname" mode="titlepage.mode">
469 <xsl:apply-templates select="." mode="common.html.attributes"/>
470 <xsl:apply-templates mode="titlepage.mode"/>
475 <xsl:template match="graphic" mode="titlepage.mode">
476 <!-- use the normal graphic handling code -->
477 <xsl:apply-templates select="."/>
480 <xsl:template match="honorific" mode="titlepage.mode">
482 <xsl:apply-templates select="." mode="common.html.attributes"/>
483 <xsl:apply-templates mode="titlepage.mode"/>
488 <xsl:template match="isbn" mode="titlepage.mode">
490 <xsl:apply-templates select="." mode="common.html.attributes"/>
491 <xsl:apply-templates mode="titlepage.mode"/>
496 <xsl:template match="issn" mode="titlepage.mode">
498 <xsl:apply-templates select="." mode="common.html.attributes"/>
499 <xsl:apply-templates mode="titlepage.mode"/>
504 <xsl:template match="biblioid" mode="titlepage.mode">
506 <xsl:apply-templates select="." mode="common.html.attributes"/>
507 <xsl:apply-templates mode="titlepage.mode"/>
512 <xsl:template match="itermset" mode="titlepage.mode">
515 <xsl:template match="invpartnumber" mode="titlepage.mode">
517 <xsl:apply-templates select="." mode="common.html.attributes"/>
518 <xsl:apply-templates mode="titlepage.mode"/>
523 <xsl:template match="issuenum" mode="titlepage.mode">
525 <xsl:apply-templates select="." mode="common.html.attributes"/>
526 <xsl:apply-templates mode="titlepage.mode"/>
531 <xsl:template match="jobtitle" mode="titlepage.mode">
533 <xsl:apply-templates select="." mode="common.html.attributes"/>
534 <xsl:apply-templates mode="titlepage.mode"/>
539 <xsl:template match="keywordset" mode="titlepage.mode">
542 <xsl:template match="legalnotice" mode="titlepage.mode">
543 <xsl:variable name="id"><xsl:call-template name="object.id"/></xsl:variable>
546 <xsl:when test="$generate.legalnotice.link != 0">
548 <!-- Compute name of legalnotice file -->
549 <xsl:variable name="file">
550 <xsl:call-template name="ln.or.rh.filename"/>
553 <xsl:variable name="filename">
554 <xsl:call-template name="make-relative-filename">
555 <xsl:with-param name="base.dir" select="$base.dir"/>
556 <xsl:with-param name="base.name" select="$file"/>
560 <xsl:variable name="title">
561 <xsl:apply-templates select="." mode="title.markup"/>
565 <xsl:copy-of select="$title"/>
568 <xsl:call-template name="write.chunk">
569 <xsl:with-param name="filename" select="$filename"/>
570 <xsl:with-param name="quiet" select="$chunk.quietly"/>
571 <xsl:with-param name="content">
572 <xsl:call-template name="user.preroot"/>
575 <xsl:call-template name="system.head.content"/>
576 <xsl:call-template name="head.content"/>
577 <xsl:call-template name="user.head.content"/>
580 <xsl:call-template name="body.attributes"/>
582 <xsl:apply-templates select="." mode="common.html.attributes"/>
583 <xsl:apply-templates mode="titlepage.mode"/>
587 <xsl:value-of select="$chunk.append"/>
593 <xsl:apply-templates select="." mode="common.html.attributes"/>
595 <xsl:apply-templates mode="titlepage.mode"/>
601 <xsl:template match="legalnotice/title" mode="titlepage.mode">
602 <p class="legalnotice-title"><b><xsl:apply-templates/></b></p>
605 <xsl:template match="lineage" mode="titlepage.mode">
607 <xsl:apply-templates select="." mode="common.html.attributes"/>
608 <xsl:apply-templates mode="titlepage.mode"/>
613 <xsl:template match="modespec" mode="titlepage.mode">
616 <xsl:template match="orgdiv" mode="titlepage.mode">
617 <xsl:if test="preceding-sibling::*[1][self::orgname]">
618 <xsl:text> </xsl:text>
621 <xsl:apply-templates select="." mode="common.html.attributes"/>
622 <xsl:apply-templates mode="titlepage.mode"/>
627 <xsl:template match="orgname" mode="titlepage.mode">
629 <xsl:apply-templates select="." mode="common.html.attributes"/>
630 <xsl:apply-templates mode="titlepage.mode"/>
635 <xsl:template match="othercredit" mode="titlepage.mode">
637 <xsl:when test="not($othercredit.like.author.enabled = 0)">
638 <xsl:variable name="contrib" select="string(contrib)"/>
640 <xsl:when test="contrib">
641 <xsl:if test="not(preceding-sibling::othercredit[string(contrib)=$contrib])">
642 <xsl:call-template name="paragraph">
643 <xsl:with-param name="class" select="local-name(.)"/>
644 <xsl:with-param name="content">
645 <xsl:apply-templates mode="titlepage.mode" select="contrib"/>
646 <xsl:text>: </xsl:text>
647 <xsl:call-template name="person.name"/>
648 <xsl:apply-templates mode="titlepage.mode" select="affiliation"/>
649 <xsl:apply-templates select="following-sibling::othercredit[string(contrib)=$contrib]" mode="titlepage.othercredits"/>
655 <xsl:call-template name="paragraph">
656 <xsl:with-param name="class" select="local-name(.)"/>
657 <xsl:with-param name="content">
658 <xsl:call-template name="person.name"/>
661 <xsl:apply-templates mode="titlepage.mode" select="affiliation"/>
666 <xsl:call-template name="credits.div"/>
671 <xsl:template match="othercredit" mode="titlepage.othercredits">
672 <xsl:text>, </xsl:text>
673 <xsl:call-template name="person.name"/>
676 <xsl:template match="othername" mode="titlepage.mode">
678 <xsl:apply-templates select="." mode="common.html.attributes"/>
679 <xsl:apply-templates mode="titlepage.mode"/>
684 <xsl:template match="pagenums" mode="titlepage.mode">
686 <xsl:apply-templates select="." mode="common.html.attributes"/>
687 <xsl:apply-templates mode="titlepage.mode"/>
692 <xsl:template match="printhistory" mode="titlepage.mode">
694 <xsl:apply-templates select="." mode="common.html.attributes"/>
695 <xsl:apply-templates mode="titlepage.mode"/>
699 <xsl:template match="productname" mode="titlepage.mode">
701 <xsl:apply-templates select="." mode="common.html.attributes"/>
702 <xsl:apply-templates mode="titlepage.mode"/>
707 <xsl:template match="productnumber" mode="titlepage.mode">
709 <xsl:apply-templates select="." mode="common.html.attributes"/>
710 <xsl:apply-templates mode="titlepage.mode"/>
715 <xsl:template match="pubdate" mode="titlepage.mode">
716 <xsl:call-template name="paragraph">
717 <xsl:with-param name="class" select="local-name(.)"/>
718 <xsl:with-param name="content">
719 <xsl:apply-templates mode="titlepage.mode"/>
724 <xsl:template match="publisher" mode="titlepage.mode">
725 <xsl:call-template name="paragraph">
726 <xsl:with-param name="class" select="local-name(.)"/>
727 <xsl:with-param name="content">
728 <xsl:apply-templates mode="titlepage.mode"/>
733 <xsl:template match="publishername" mode="titlepage.mode">
735 <xsl:apply-templates select="." mode="common.html.attributes"/>
736 <xsl:apply-templates mode="titlepage.mode"/>
741 <xsl:template match="pubsnumber" mode="titlepage.mode">
743 <xsl:apply-templates select="." mode="common.html.attributes"/>
744 <xsl:apply-templates mode="titlepage.mode"/>
749 <xsl:template match="releaseinfo" mode="titlepage.mode">
750 <xsl:call-template name="paragraph">
751 <xsl:with-param name="class" select="local-name(.)"/>
752 <xsl:with-param name="content">
753 <xsl:apply-templates mode="titlepage.mode"/>
758 <xsl:template match="revhistory" mode="titlepage.mode">
759 <xsl:variable name="numcols">
761 <xsl:when test=".//authorinitials|.//author">3</xsl:when>
762 <xsl:otherwise>2</xsl:otherwise>
766 <xsl:variable name="id"><xsl:call-template name="object.id"/></xsl:variable>
768 <xsl:variable name="title">
769 <xsl:call-template name="gentext">
770 <xsl:with-param name="key">RevHistory</xsl:with-param>
774 <xsl:variable name="contents">
776 <xsl:apply-templates select="." mode="common.html.attributes"/>
777 <table border="1" width="100%" summary="Revision history">
779 <th align="{$direction.align.start}" valign="top" colspan="{$numcols}">
781 <xsl:call-template name="gentext">
782 <xsl:with-param name="key" select="'RevHistory'"/>
787 <xsl:apply-templates mode="titlepage.mode">
788 <xsl:with-param name="numcols" select="$numcols"/>
789 </xsl:apply-templates>
795 <xsl:when test="$generate.revhistory.link != 0">
797 <!-- Compute name of revhistory file -->
798 <xsl:variable name="file">
799 <xsl:call-template name="ln.or.rh.filename">
800 <xsl:with-param name="is.ln" select="false()"/>
804 <xsl:variable name="filename">
805 <xsl:call-template name="make-relative-filename">
806 <xsl:with-param name="base.dir" select="$base.dir"/>
807 <xsl:with-param name="base.name" select="$file"/>
812 <xsl:copy-of select="$title"/>
815 <xsl:call-template name="write.chunk">
816 <xsl:with-param name="filename" select="$filename"/>
817 <xsl:with-param name="quiet" select="$chunk.quietly"/>
818 <xsl:with-param name="content">
819 <xsl:call-template name="user.preroot"/>
822 <xsl:call-template name="system.head.content"/>
823 <xsl:call-template name="head.content">
824 <xsl:with-param name="title">
825 <xsl:value-of select="$title"/>
826 <xsl:if test="../../title">
827 <xsl:value-of select="concat(' (', ../../title, ')')"/>
831 <xsl:call-template name="user.head.content"/>
834 <xsl:call-template name="body.attributes"/>
835 <xsl:copy-of select="$contents"/>
838 <xsl:text>
</xsl:text>
843 <xsl:copy-of select="$contents"/>
848 <xsl:template match="revhistory/revision" mode="titlepage.mode">
849 <xsl:param name="numcols" select="'3'"/>
850 <xsl:variable name="revnumber" select="revnumber"/>
851 <xsl:variable name="revdate" select="date"/>
852 <xsl:variable name="revauthor" select="authorinitials|author"/>
853 <xsl:variable name="revremark" select="revremark|revdescription"/>
855 <td align="{$direction.align.start}">
856 <xsl:if test="$revnumber">
857 <xsl:call-template name="gentext">
858 <xsl:with-param name="key" select="'Revision'"/>
860 <xsl:call-template name="gentext.space"/>
861 <xsl:apply-templates select="$revnumber[1]" mode="titlepage.mode"/>
864 <td align="{$direction.align.start}">
865 <xsl:apply-templates select="$revdate[1]" mode="titlepage.mode"/>
868 <xsl:when test="$revauthor">
869 <td align="{$direction.align.start}">
870 <xsl:for-each select="$revauthor">
871 <xsl:apply-templates select="." mode="titlepage.mode"/>
872 <xsl:if test="position() != last()">
873 <xsl:text>, </xsl:text>
878 <xsl:when test="$numcols > 2">
881 <xsl:otherwise></xsl:otherwise>
884 <xsl:if test="$revremark">
886 <td align="{$direction.align.start}" colspan="{$numcols}">
887 <xsl:apply-templates select="$revremark[1]" mode="titlepage.mode"/>
893 <xsl:template match="revision/revnumber" mode="titlepage.mode">
894 <xsl:apply-templates mode="titlepage.mode"/>
897 <xsl:template match="revision/date" mode="titlepage.mode">
898 <xsl:apply-templates mode="titlepage.mode"/>
901 <xsl:template match="revision/authorinitials" mode="titlepage.mode">
902 <xsl:apply-templates mode="titlepage.mode"/>
905 <xsl:template match="revision/author" mode="titlepage.mode">
906 <xsl:apply-templates mode="titlepage.mode"/>
909 <xsl:template match="revision/revremark" mode="titlepage.mode">
910 <xsl:apply-templates mode="titlepage.mode"/>
913 <xsl:template match="revision/revdescription" mode="titlepage.mode">
914 <xsl:apply-templates mode="titlepage.mode"/>
917 <xsl:template match="seriesvolnums" mode="titlepage.mode">
919 <xsl:apply-templates select="." mode="common.html.attributes"/>
920 <xsl:apply-templates mode="titlepage.mode"/>
925 <xsl:template match="shortaffil" mode="titlepage.mode">
927 <xsl:apply-templates select="." mode="common.html.attributes"/>
928 <xsl:apply-templates mode="titlepage.mode"/>
933 <xsl:template match="subjectset" mode="titlepage.mode">
936 <xsl:template match="subtitle" mode="titlepage.mode">
938 <xsl:apply-templates select="." mode="common.html.attributes"/>
939 <xsl:apply-templates mode="titlepage.mode"/>
943 <xsl:template match="surname" mode="titlepage.mode">
945 <xsl:apply-templates select="." mode="common.html.attributes"/>
946 <xsl:apply-templates mode="titlepage.mode"/>
951 <xsl:template match="title" mode="titlepage.mode">
952 <xsl:variable name="id">
954 <!-- if title is in an *info wrapper, get the grandparent -->
955 <xsl:when test="contains(local-name(..), 'info')">
956 <xsl:call-template name="object.id">
957 <xsl:with-param name="object" select="../.."/>
961 <xsl:call-template name="object.id">
962 <xsl:with-param name="object" select=".."/>
969 <xsl:apply-templates select="." mode="common.html.attributes"/>
970 <xsl:if test="$generate.id.attributes = 0">
974 <xsl:when test="$show.revisionflag != 0 and @revisionflag">
975 <span class="{@revisionflag}">
976 <xsl:apply-templates mode="titlepage.mode"/>
980 <xsl:apply-templates mode="titlepage.mode"/>
986 <xsl:template match="titleabbrev" mode="titlepage.mode">
987 <!-- nop; title abbreviations don't belong on the title page! -->
990 <xsl:template match="volumenum" mode="titlepage.mode">
992 <xsl:apply-templates select="." mode="common.html.attributes"/>
993 <xsl:apply-templates mode="titlepage.mode"/>
998 <!-- This template computes the filename for legalnotice and revhistory chunks -->
999 <xsl:template name="ln.or.rh.filename">
1000 <xsl:param name="node" select="."/>
1001 <xsl:param name="is.ln" select="true()"/>
1003 <xsl:variable name="dbhtml-filename">
1004 <xsl:call-template name="pi.dbhtml_filename">
1005 <xsl:with-param name="node" select="$node"/>
1006 </xsl:call-template>
1010 <!-- 1. If there is a dbhtml_filename PI, use that -->
1011 <xsl:when test="$dbhtml-filename != ''">
1012 <xsl:value-of select="$dbhtml-filename"/>
1014 <xsl:when test="($node/@id or $node/@xml:id) and not($use.id.as.filename = 0)">
1015 <!-- * 2. If this legalnotice/revhistory has an ID, then go ahead and use -->
1016 <!-- * just the value of that ID as the basename for the file -->
1017 <!-- * (that is, without prepending an "ln-" or "rh-" to it) -->
1018 <xsl:value-of select="($node/@id|$node/@xml:id)[1]"/>
1019 <xsl:value-of select="$html.ext"/>
1021 <xsl:when test="not ($node/@id or $node/@xml:id) or $use.id.as.filename = 0">
1022 <!-- * 3. Otherwise, if this legalnotice/revhistory does not have an ID, or -->
1023 <!-- * if $use.id.as.filename = 0 -->
1024 <!-- * then we generate an ID... -->
1025 <xsl:variable name="id">
1026 <xsl:value-of select="generate-id($node)"/>
1028 <!-- * ...and then we take that generated ID, prepend a -->
1029 <!-- * prefix to it, and use that as the basename for the file -->
1031 <xsl:when test="$is.ln">
1032 <xsl:value-of select="concat('ln-',$id,$html.ext)"/>
1035 <xsl:value-of select="concat('rh-',$id,$html.ext)"/>
1042 <!-- ==================================================================== -->