1
<?xml version="1.0" encoding="ISO-8859-1"?>
2
<!-- Customization layer for PDF output
3
License: CC-BY-SA. see http://creativecommons.org/licenses/by-sa/2.0/
6
<xsl:stylesheet version="1.0"
7
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
8
xmlns:fo="http://www.w3.org/1999/XSL/Format">
10
<!-- Import the new xsl -->
11
<xsl:import href="/home/matt/tmp/docbook-xsl-snapshot/fo/docbook.xsl"/>
13
<!-- *************** Fonts ********************* -->
14
<!-- *************************************************** -->
16
<!-- Use a serif font -->
17
<xsl:param name="body.font.family" select="'serif'"/>
18
<xsl:param name="symbol.font.family" select="'Symbol'"/>
19
<xsl:param name="dingbat.font.family">
20
<xsl:value-of select="$body.font.family"/>
22
<xsl:param name="title.font.family">
23
<xsl:value-of select="$body.font.family"/>
25
<xsl:param name="body.font.master">11</xsl:param>
26
<xsl:param name="body.font.size">
27
<xsl:value-of select="$body.font.master"/><xsl:text>pt</xsl:text>
30
<xsl:param name="monospace.font.family" select="'monospace'"></xsl:param>
32
<!-- Smaller monospace -->
33
<xsl:attribute-set name="monospace.properties">
34
<xsl:attribute name="font-size">80%</xsl:attribute>
37
<xsl:param name="line-height" select="'1.5'"></xsl:param>
39
<!-- *************** Page Format ********************* -->
40
<!-- *************************************************** -->
42
<!-- Define the page width/height -->
43
<xsl:param name="page.width">21cm</xsl:param>
44
<xsl:param name="page.height">29.7cm</xsl:param>
46
<!-- Give each section a number -->
47
<xsl:param name="section.autolabel" select="1"></xsl:param>
49
<!-- Turn on left justify. The default is full justify -->
50
<xsl:param name="alignment">left</xsl:param>
53
<xsl:param name="page.margin.outer">
55
<xsl:when test="$double.sided != 0">0.75in</xsl:when>
56
<xsl:otherwise>1in</xsl:otherwise>
59
<xsl:param name="page.margin.inner">
61
<xsl:when test="$double.sided != 0">1in</xsl:when>
62
<xsl:otherwise>1in</xsl:otherwise>
66
<!-- Keep paragraphs flush with the left hand side -->
67
<xsl:param name="body.start.indent" select="'0pc'"/>
68
<xsl:param name="title.margin.left" select="'0pc'"/>
70
<!-- Put a rule above each footer and a rule below each header -->
71
<xsl:param name="footer.rule" select="0"/>
72
<xsl:param name="header.rule" select="1"/>
74
<!-- Don't split words across lines (no end-of-line word breaks) -->
75
<xsl:param name="hyphenate">false</xsl:param>
77
<!-- '1 3 1' means the center header has three times the width of the left and
78
right headers. This is needed because the doc title is in the center header -->
79
<xsl:param name="header.column.widths" select="'1 3 1'"/>
81
<!-- *************** Headers ********************* -->
82
<!-- *************************************************** -->
84
<xsl:attribute-set name="section.title.properties">
85
<xsl:attribute name="font-family">
86
<xsl:value-of select="$title.font.family"></xsl:value-of>
88
<xsl:attribute name="font-weight">normal</xsl:attribute>
89
<!-- font size is calculated dynamically by section.heading template -->
90
<xsl:attribute name="keep-with-next.within-column">always</xsl:attribute>
91
<xsl:attribute name="space-before.minimum">0.8em</xsl:attribute>
92
<xsl:attribute name="space-before.optimum">1.0em</xsl:attribute>
93
<xsl:attribute name="space-before.maximum">1.2em</xsl:attribute>
94
<xsl:attribute name="text-align">left</xsl:attribute>
95
<xsl:attribute name="start-indent"><xsl:value-of select="$title.margin.left"></xsl:value-of></xsl:attribute>
98
<xsl:attribute-set name="section.title.level1.properties">
99
<xsl:attribute name="font-weight">bold</xsl:attribute>
100
<xsl:attribute name="text-decoration">underline</xsl:attribute>
101
<xsl:attribute name="font-size">
102
<xsl:value-of select="$body.font.master * 1.5"></xsl:value-of>
103
<xsl:text>pt</xsl:text>
105
<xsl:attribute name="break-before">page</xsl:attribute>
108
<xsl:attribute-set name="section.title.level2.properties">
109
<xsl:attribute name="text-decoration">underline</xsl:attribute>
110
<xsl:attribute name="font-size">
111
<xsl:value-of select="$body.font.master * 1.3"></xsl:value-of>
112
<xsl:text>pt</xsl:text>
116
<xsl:attribute-set name="section.title.level3.properties">
117
<xsl:attribute name="text-decoration">underline</xsl:attribute>
118
<xsl:attribute name="font-size">
119
<xsl:value-of select="$body.font.master * 1"></xsl:value-of>
120
<xsl:text>pt</xsl:text>
124
<xsl:attribute-set name="section.title.level4.properties">
125
<xsl:attribute name="font-style">italic</xsl:attribute>
126
<xsl:attribute name="font-size">
127
<xsl:value-of select="$body.font.master * 1"></xsl:value-of>
128
<xsl:text>pt</xsl:text>
132
<!-- *************** Links ********************* -->
133
<!-- *************************************************** -->
135
<!-- urls in brackets for ulinks -->
136
<xsl:param name="ulink.show" select="1"></xsl:param>
138
<!-- ulink formatting -->
139
<xsl:attribute-set name="xref.properties">
140
<xsl:attribute name="font-style">italic</xsl:attribute>
143
<!-- footnotes (uncomment if they fix fop)
145
<xsl:param name="ulink.footnotes" select="'yes'"></xsl:param>
146
<xsl:attribute-set name="footnote.mark.properties">
147
<xsl:attribute name="font-size">65%</xsl:attribute>
148
<xsl:attribute name="font-weight">normal</xsl:attribute>
149
<xsl:attribute name="font-style">normal</xsl:attribute>
151
<xsl:attribute-set name="footnote.properties">
152
<xsl:attribute name="font-size">70%</xsl:attribute>
153
<xsl:attribute name="font-weight">normal</xsl:attribute>
154
<xsl:attribute name="font-style">normal</xsl:attribute>
159
<!-- page numbers included in xref cross references -->
160
<xsl:param name="insert.xref.page.number">yes</xsl:param>
162
<!-- This customises the page number format -->
163
<xsl:param name="local.l10n.xml" select="document('')"/>
164
<l:i18n xmlns:l="http://docbook.sourceforge.net/xmlns/l10n/1.0">
165
<l:l10n language="en">
166
<l:context name="xref">
167
<l:template name="page.citation" text=" [p. %p]"/>
172
<!-- *************** Admonitions ********************* -->
173
<!-- *************************************************** -->
175
<!-- If true (non-zero), admonitions are presented in an alternate style that uses a graphic. Default graphics are provided in the distribution. -->
176
<xsl:param name="admon.graphics" select="1"></xsl:param>
178
<!-- If true (non-zero), admonitions are presented with a generated text label such as Note or Warning in the appropriate language. If zero, such labels are turned off, but any title children of the admonition element are still output. The default value is 1. -->
179
<xsl:param name="admon.textlabel" select="0"></xsl:param>
181
<xsl:param name="admon.graphics.path" select="'../../../../common/admon-lulu/'"/>
182
<xsl:param name="admon.graphics.extension" select="'.png'"/>
184
<xsl:template match="*" mode="admon.graphic.width">
185
<xsl:text>24pt</xsl:text>
188
<!-- *************** ToC/LoT/Index Generation ********************* -->
189
<!-- *************************************************** -->
191
<!-- Specifies the depth to which recursive sections should appear in the TOC -->
192
<xsl:param name="toc.section.depth" select="1" />
194
<!-- How maximaly deep should be each TOC? -->
195
<xsl:param name="toc.max.depth" select="2" />
197
<!-- **************** Miscellaneous Fixes ****************** -->
198
<!-- *************************************************** -->
200
<!-- Some custom spacing for lists -->
202
<xsl:attribute-set name="list.block.spacing">
203
<xsl:attribute name="space-before.optimum">0.3em</xsl:attribute>
204
<xsl:attribute name="space-before.minimum">0.2em</xsl:attribute>
205
<xsl:attribute name="space-before.maximum">0.5em</xsl:attribute>
206
<xsl:attribute name="space-after.optimum">0.3em</xsl:attribute>
207
<xsl:attribute name="space-after.minimum">0.2em</xsl:attribute>
208
<xsl:attribute name="space-after.maximum">0.5em</xsl:attribute>
211
<xsl:attribute-set name="list.item.spacing">
212
<xsl:attribute name="space-before.optimum">0.3em</xsl:attribute>
213
<xsl:attribute name="space-before.minimum">0.2em</xsl:attribute>
214
<xsl:attribute name="space-before.maximum">0.5em</xsl:attribute>
217
<xsl:param name="variablelist.as.blocks" select="1"></xsl:param>
219
<!-- Get rid of annoying white page after titlepage -->
220
<xsl:template name="book.titlepage.separator"/>
222
<xsl:param name="fop1.extensions" select="'yes'"/>
223
<xsl:param name="fop.extensions" select="'yes'"/>
224
<xsl:template match="*" mode="fop.outline"/>
226
<!-- select draft mode, either yes or no -->
227
<xsl:param name="draft.mode" select="'no'"/>