1 | <?xml version='1.0'?>
|
---|
2 | <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
---|
3 | xmlns:fo="http://www.w3.org/1999/XSL/Format"
|
---|
4 | version='1.0'>
|
---|
5 |
|
---|
6 | <!-- ********************************************************************
|
---|
7 | $Id$
|
---|
8 | ********************************************************************
|
---|
9 |
|
---|
10 | This file is part of the XSL DocBook Stylesheet distribution.
|
---|
11 | See ../README or http://nwalsh.com/docbook/xsl/ for copyright
|
---|
12 | and other information.
|
---|
13 |
|
---|
14 | ******************************************************************** -->
|
---|
15 |
|
---|
16 | <!-- ==================================================================== -->
|
---|
17 |
|
---|
18 | <xsl:template match="reference">
|
---|
19 | <xsl:if test="not(partintro)">
|
---|
20 | <xsl:variable name="id">
|
---|
21 | <xsl:call-template name="object.id"/>
|
---|
22 | </xsl:variable>
|
---|
23 | <xsl:variable name="master-name">
|
---|
24 | <xsl:call-template name="select.pagemaster"/>
|
---|
25 | </xsl:variable>
|
---|
26 |
|
---|
27 | <fo:page-sequence id="{$id}"
|
---|
28 | hyphenate="{$hyphenate}"
|
---|
29 | master-name="{$master-name}">
|
---|
30 | <xsl:attribute name="language">
|
---|
31 | <xsl:call-template name="l10n.language"/>
|
---|
32 | </xsl:attribute>
|
---|
33 | <xsl:if test="$double.sided != 0">
|
---|
34 | <xsl:attribute name="force-page-count">end-on-even</xsl:attribute>
|
---|
35 | </xsl:if>
|
---|
36 |
|
---|
37 | <xsl:apply-templates select="." mode="running.head.mode">
|
---|
38 | <xsl:with-param name="master-name" select="$master-name"/>
|
---|
39 | </xsl:apply-templates>
|
---|
40 | <xsl:apply-templates select="." mode="running.foot.mode">
|
---|
41 | <xsl:with-param name="master-name" select="$master-name"/>
|
---|
42 | </xsl:apply-templates>
|
---|
43 |
|
---|
44 | <fo:flow flow-name="xsl-region-body">
|
---|
45 | <xsl:call-template name="reference.titlepage"/>
|
---|
46 | </fo:flow>
|
---|
47 | </fo:page-sequence>
|
---|
48 | </xsl:if>
|
---|
49 | <xsl:apply-templates select="partintro|refentry"/>
|
---|
50 | </xsl:template>
|
---|
51 |
|
---|
52 | <xsl:template match="reference" mode="reference.titlepage.mode">
|
---|
53 | <xsl:call-template name="reference.titlepage"/>
|
---|
54 | </xsl:template>
|
---|
55 |
|
---|
56 | <xsl:template match="reference/partintro">
|
---|
57 | <xsl:variable name="id">
|
---|
58 | <xsl:call-template name="object.id">
|
---|
59 | <xsl:with-param name="object" select="ancestor::reference"/>
|
---|
60 | </xsl:call-template>
|
---|
61 | </xsl:variable>
|
---|
62 | <xsl:variable name="master-name">
|
---|
63 | <xsl:call-template name="select.pagemaster"/>
|
---|
64 | </xsl:variable>
|
---|
65 |
|
---|
66 | <fo:page-sequence id="{$id}"
|
---|
67 | hyphenate="{$hyphenate}"
|
---|
68 | master-name="{$master-name}">
|
---|
69 | <xsl:attribute name="language">
|
---|
70 | <xsl:call-template name="l10n.language"/>
|
---|
71 | </xsl:attribute>
|
---|
72 | <xsl:if test="$double.sided != 0">
|
---|
73 | <xsl:attribute name="force-page-count">end-on-even</xsl:attribute>
|
---|
74 | </xsl:if>
|
---|
75 |
|
---|
76 | <xsl:apply-templates select="." mode="running.head.mode">
|
---|
77 | <xsl:with-param name="master-name" select="$master-name"/>
|
---|
78 | </xsl:apply-templates>
|
---|
79 | <xsl:apply-templates select="." mode="running.foot.mode">
|
---|
80 | <xsl:with-param name="master-name" select="$master-name"/>
|
---|
81 | </xsl:apply-templates>
|
---|
82 |
|
---|
83 | <fo:flow flow-name="xsl-region-body">
|
---|
84 | <xsl:apply-templates select=".." mode="reference.titlepage.mode"/>
|
---|
85 | <xsl:if test="title">
|
---|
86 | <xsl:call-template name="partintro.titlepage"/>
|
---|
87 | </xsl:if>
|
---|
88 | <xsl:apply-templates/>
|
---|
89 | </fo:flow>
|
---|
90 | </fo:page-sequence>
|
---|
91 | </xsl:template>
|
---|
92 |
|
---|
93 | <xsl:template match="reference/docinfo"></xsl:template>
|
---|
94 | <xsl:template match="reference/title"></xsl:template>
|
---|
95 | <xsl:template match="reference/subtitle"></xsl:template>
|
---|
96 |
|
---|
97 | <!-- ==================================================================== -->
|
---|
98 |
|
---|
99 | <xsl:template match="refentry">
|
---|
100 | <xsl:variable name="id">
|
---|
101 | <xsl:call-template name="object.id"/>
|
---|
102 | </xsl:variable>
|
---|
103 | <xsl:variable name="master-name">
|
---|
104 | <xsl:call-template name="select.pagemaster"/>
|
---|
105 | </xsl:variable>
|
---|
106 |
|
---|
107 | <fo:page-sequence id="{$id}"
|
---|
108 | hyphenate="{$hyphenate}"
|
---|
109 | master-name="{$master-name}">
|
---|
110 | <xsl:attribute name="language">
|
---|
111 | <xsl:call-template name="l10n.language"/>
|
---|
112 | </xsl:attribute>
|
---|
113 | <xsl:if test="$double.sided != 0">
|
---|
114 | <xsl:attribute name="force-page-count">end-on-even</xsl:attribute>
|
---|
115 | </xsl:if>
|
---|
116 |
|
---|
117 | <xsl:apply-templates select="." mode="running.head.mode">
|
---|
118 | <xsl:with-param name="master-name" select="$master-name"/>
|
---|
119 | </xsl:apply-templates>
|
---|
120 | <xsl:apply-templates select="." mode="running.foot.mode">
|
---|
121 | <xsl:with-param name="master-name" select="$master-name"/>
|
---|
122 | </xsl:apply-templates>
|
---|
123 |
|
---|
124 | <fo:flow flow-name="xsl-region-body">
|
---|
125 | <fo:block font-size="20pt" font-weight="bold">
|
---|
126 | <!-- FIXME: is this right? -->
|
---|
127 | <xsl:choose>
|
---|
128 | <xsl:when test="refmeta/refentrytitle">
|
---|
129 | <xsl:apply-templates select="refmeta/refentrytitle" mode="title"/>
|
---|
130 | </xsl:when>
|
---|
131 | <xsl:when test="refnamediv/refname">
|
---|
132 | <xsl:apply-templates select="refnamediv/refname" mode="title"/>
|
---|
133 | </xsl:when>
|
---|
134 | </xsl:choose>
|
---|
135 | </fo:block>
|
---|
136 | <xsl:apply-templates/>
|
---|
137 | </fo:flow>
|
---|
138 | </fo:page-sequence>
|
---|
139 | </xsl:template>
|
---|
140 |
|
---|
141 | <xsl:template match="refmeta">
|
---|
142 | </xsl:template>
|
---|
143 |
|
---|
144 | <xsl:template match="manvolnum">
|
---|
145 | <xsl:if test="$refentry.xref.manvolnum != 0">
|
---|
146 | <xsl:text>(</xsl:text>
|
---|
147 | <xsl:apply-templates/>
|
---|
148 | <xsl:text>)</xsl:text>
|
---|
149 | </xsl:if>
|
---|
150 | </xsl:template>
|
---|
151 |
|
---|
152 | <xsl:template match="refmiscinfo">
|
---|
153 | </xsl:template>
|
---|
154 |
|
---|
155 | <xsl:template match="refentrytitle">
|
---|
156 | <xsl:call-template name="inline.charseq"/>
|
---|
157 | </xsl:template>
|
---|
158 |
|
---|
159 | <xsl:template match="refnamediv">
|
---|
160 | <xsl:call-template name="block.object"/>
|
---|
161 | </xsl:template>
|
---|
162 |
|
---|
163 | <xsl:template match="refname">
|
---|
164 | <xsl:if test="$refentry.generate.name != 0">
|
---|
165 | <fo:block font-size="18pt" font-weight="bold">
|
---|
166 | <xsl:call-template name="gentext">
|
---|
167 | <xsl:with-param name="key" select="'RefName'"/>
|
---|
168 | </xsl:call-template>
|
---|
169 | </fo:block>
|
---|
170 | </xsl:if>
|
---|
171 | <xsl:apply-templates/>
|
---|
172 | <xsl:if test="following-sibling::refname">
|
---|
173 | <xsl:text>, </xsl:text>
|
---|
174 | </xsl:if>
|
---|
175 | </xsl:template>
|
---|
176 |
|
---|
177 | <xsl:template match="refpurpose">
|
---|
178 | <xsl:text> </xsl:text>
|
---|
179 | <xsl:call-template name="dingbat">
|
---|
180 | <xsl:with-param name="dingbat">em-dash</xsl:with-param>
|
---|
181 | </xsl:call-template>
|
---|
182 | <xsl:text> </xsl:text>
|
---|
183 | <xsl:apply-templates/>
|
---|
184 | </xsl:template>
|
---|
185 |
|
---|
186 | <xsl:template match="refdescriptor">
|
---|
187 | <!-- todo: finish this -->
|
---|
188 | </xsl:template>
|
---|
189 |
|
---|
190 | <xsl:template match="refclass">
|
---|
191 | <fo:block font-weight="bold">
|
---|
192 | <xsl:if test="@role">
|
---|
193 | <xsl:value-of select="@role"/>
|
---|
194 | <xsl:text>: </xsl:text>
|
---|
195 | </xsl:if>
|
---|
196 | <xsl:apply-templates/>
|
---|
197 | </fo:block>
|
---|
198 | </xsl:template>
|
---|
199 |
|
---|
200 | <xsl:template match="refsynopsisdiv">
|
---|
201 | <fo:block>
|
---|
202 | <fo:block font-size="18pt" font-weight="bold">
|
---|
203 | <xsl:text>Synopsis (what about the title?)</xsl:text>
|
---|
204 | </fo:block>
|
---|
205 | <xsl:apply-templates/>
|
---|
206 | </fo:block>
|
---|
207 | </xsl:template>
|
---|
208 |
|
---|
209 | <xsl:template match="refsynopsisdiv/title">
|
---|
210 | </xsl:template>
|
---|
211 |
|
---|
212 | <xsl:template match="refsect1|refsect2|refsect3">
|
---|
213 | <xsl:call-template name="block.object"/>
|
---|
214 | </xsl:template>
|
---|
215 |
|
---|
216 | <xsl:template match="refsect1/title">
|
---|
217 | <fo:block font-size="18pt" font-weight="bold">
|
---|
218 | <xsl:apply-templates/>
|
---|
219 | </fo:block>
|
---|
220 | </xsl:template>
|
---|
221 |
|
---|
222 | <xsl:template match="refsect2/title">
|
---|
223 | <fo:block font-size="16pt" font-weight="bold">
|
---|
224 | <xsl:apply-templates/>
|
---|
225 | </fo:block>
|
---|
226 | </xsl:template>
|
---|
227 |
|
---|
228 | <xsl:template match="refsect3/title">
|
---|
229 | <fo:block font-size="14pt" font-weight="bold">
|
---|
230 | <xsl:apply-templates/>
|
---|
231 | </fo:block>
|
---|
232 | </xsl:template>
|
---|
233 |
|
---|
234 | <!-- ==================================================================== -->
|
---|
235 |
|
---|
236 | </xsl:stylesheet>
|
---|