source: clfs-embedded/BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/fo/pi.xsl@ 14af48c

Last change on this file since 14af48c was 9882b55, checked in by Manuel Canales Esparcia <manuel@…>, 17 years ago

Added the new lfs-xsl stylesheets.

  • Property mode set to 100644
File size: 31.0 KB
Line 
1<?xml version='1.0'?>
2<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
3 xmlns:doc="http://nwalsh.com/xsl/documentation/1.0"
4 xmlns:fo="http://www.w3.org/1999/XSL/Format"
5 exclude-result-prefixes="doc"
6 version='1.0'>
7
8<!-- ********************************************************************
9 $Id$
10 ********************************************************************
11
12 This file is part of the XSL DocBook Stylesheet distribution.
13 See ../README or http://docbook.sf.net/release/xsl/current/ for
14 copyright and other information.
15
16 ******************************************************************** -->
17
18<doc:reference xmlns="">
19<referenceinfo>
20<releaseinfo role="meta">
21$Id$
22</releaseinfo>
23<authorgroup>
24 <author>
25 <orgname>The DocBook Project Development Team</orgname>
26 </author>
27</authorgroup>
28<copyright>
29 <year>2007</year>
30 <holder>The DocBook Project</holder>
31</copyright>
32</referenceinfo>
33<title>FO Processing Instruction Reference</title>
34
35<partintro id="partintro">
36<title>Introduction</title>
37
38<para>This is generated reference documentation for all
39 user-configurable processing instructions (PIs) in the DocBook
40 XSL stylesheets for FO output.
41 <note>
42 <para>You add these PIs at particular points in a document to
43 cause specific “exceptions” to formatting/output behavior. To
44 make global changes in formatting/output behavior across an
45 entire document, it’s better to do it by setting an
46 appropriate stylesheet parameter (if there is one).</para>
47 </note>
48</para>
49</partintro>
50</doc:reference>
51
52<!-- ==================================================================== -->
53
54<doc:pi name="dbfo_background-color" xmlns="">
55<refpurpose>Sets background color for an image</refpurpose>
56<refdescription>
57 <para>Use the <tag>dbfo background-color</tag> PI before or
58 after an image (<tag>graphic</tag>, <tag>inlinegraphic</tag>,
59 <tag>imagedata</tag>, or <tag>videodata</tag> element) as a
60 sibling to the element, to set a background color for the
61 image.</para>
62</refdescription>
63 <refsynopsisdiv>
64 <synopsis><tag class="xmlpi">dbfo background-color="<replaceable>color</replaceable>"</tag></synopsis>
65 </refsynopsisdiv>
66<refparameter>
67 <variablelist>
68 <varlistentry><term>background-color="<replaceable>color</replaceable>"</term>
69 <listitem>
70 <para>FIXME: A color value? [In hex, as a name, or what?]</para>
71 </listitem>
72 </varlistentry>
73 </variablelist>
74</refparameter>
75</doc:pi>
76<xsl:template name="pi.dbfo_background-color">
77 <xsl:param name="node" select="."/>
78 <xsl:call-template name="dbfo-attribute">
79 <xsl:with-param name="pis" select="$node/processing-instruction('dbfo')"/>
80 <xsl:with-param name="attribute" select="'background-color'"/>
81 </xsl:call-template>
82</xsl:template>
83
84<doc:pi name="dbfo_bgcolor" xmlns="">
85<refpurpose>Sets background color on an table row or table cell</refpurpose>
86<refdescription>
87 <para>Use the <tag>dbfo bgcolor</tag> PI as child of a table row
88 or cell to set a background color for that table row or cell.</para>
89</refdescription>
90 <refsynopsisdiv>
91 <synopsis><tag class="xmlpi">dbfo bgcolor="<replaceable>color</replaceable>"</tag></synopsis>
92 </refsynopsisdiv>
93<refparameter>
94 <variablelist>
95 <varlistentry><term>bgcolor="<replaceable>color</replaceable>"</term>
96 <listitem>
97 <para>FIXME: A color value? [In hex, as a name, or what?]</para>
98 </listitem>
99 </varlistentry>
100 </variablelist>
101</refparameter>
102</doc:pi>
103<xsl:template name="pi.dbfo_bgcolor">
104 <xsl:param name="node" select="."/>
105 <xsl:call-template name="dbfo-attribute">
106 <xsl:with-param name="pis" select="$node/processing-instruction('dbfo')"/>
107 <xsl:with-param name="attribute" select="'bgcolor'"/>
108 </xsl:call-template>
109</xsl:template>
110
111<doc:pi name="dbfo_float-type" xmlns="">
112<refpurpose>Specifies float behavior for a sidebar</refpurpose>
113<refdescription>
114 <para>Use the <tag>dbfo float-type</tag> PI to specify the float
115 behavior for a <tag>sidebar</tag> (to cause the sidebar to be
116 displayed as a marginal note).</para>
117</refdescription>
118 <refsynopsisdiv>
119 <synopsis><tag class="xmlpi">dbfo float-type="margin.note"</tag></synopsis>
120 </refsynopsisdiv>
121<refparameter>
122 <variablelist>
123 <varlistentry><term>float-type="margin.note"</term>
124 <listitem>
125 <para>Specifies that the <tag>sidebar</tag> should be
126 displayed as a marginal note.</para>
127 </listitem>
128 </varlistentry>
129 </variablelist>
130</refparameter>
131</doc:pi>
132<xsl:template name="pi.dbfo_float-type">
133 <xsl:param name="node" select="."/>
134 <xsl:call-template name="dbfo-attribute">
135 <xsl:with-param name="pis" select="$node/processing-instruction('dbfo')"/>
136 <xsl:with-param name="attribute" select="'float-type'"/>
137 </xsl:call-template>
138</xsl:template>
139
140<doc:pi name="dbfo_glossary-presentation" xmlns="">
141<refpurpose>Specifies presentation style for a glossary</refpurpose>
142<refdescription>
143 <para>Use the <tag>dbfo glossary-presentation</tag> PI as a child of
144 a <tag>glossary</tag> to control its presentation style.</para>
145</refdescription>
146 <refsynopsisdiv>
147 <synopsis><tag class="xmlpi">dbfo glossary-presentation="list"|"blocks"</tag></synopsis>
148 </refsynopsisdiv>
149<refparameter>
150 <variablelist>
151 <varlistentry><term>glossary-presentation="list"</term>
152 <listitem>
153 <para>Displayed the glossary as a list</para>
154 </listitem>
155 </varlistentry>
156 <varlistentry><term>glossary-presentation="blocks"</term>
157 <listitem>
158 <para>Displays the glossary as blocks</para>
159 </listitem>
160 </varlistentry>
161 </variablelist>
162</refparameter>
163</doc:pi>
164<xsl:template name="pi.dbfo_glossary-presentation">
165 <xsl:param name="node" select="."/>
166 <xsl:call-template name="dbfo-attribute">
167 <xsl:with-param name="pis" select="$node/processing-instruction('dbfo')"/>
168 <xsl:with-param name="attribute" select="'glossary-presentation'"/>
169 </xsl:call-template>
170</xsl:template>
171
172<doc:pi name="dbfo_glosslist-presentation" xmlns="">
173<refpurpose>Specifies presentation style for a glosslist</refpurpose>
174<refdescription>
175 <para>Use the <tag>dbfo glosslist-presentation</tag> PI as a child of
176 a <tag>glosslist</tag> to control its presentation style.</para>
177</refdescription>
178 <refsynopsisdiv>
179 <synopsis><tag class="xmlpi">dbfo glosslist-presentation="list"|"blocks"</tag></synopsis>
180 </refsynopsisdiv>
181<refparameter>
182 <variablelist>
183 <varlistentry><term>glosslist-presentation="list"</term>
184 <listitem>
185 <para>Displayed the glosslist as a list</para>
186 </listitem>
187 </varlistentry>
188 <varlistentry><term>glosslist-presentation="blocks"</term>
189 <listitem>
190 <para>Displays the glosslist as blocks</para>
191 </listitem>
192 </varlistentry>
193 </variablelist>
194</refparameter>
195</doc:pi>
196<xsl:template name="pi.dbfo_glosslist-presentation">
197 <xsl:param name="node" select="."/>
198 <xsl:call-template name="dbfo-attribute">
199 <xsl:with-param name="pis" select="$node/processing-instruction('dbfo')"/>
200 <xsl:with-param name="attribute" select="'glosslist-presentation'"/>
201 </xsl:call-template>
202</xsl:template>
203
204<doc:pi name="dbfo_glossterm-width" xmlns="">
205<refpurpose>Specifies the glossterm width for a glossary or
206 glosslist</refpurpose>
207<refdescription>
208 <para>Use the <tag>dbfo glossterm-width</tag> PI as a child of a
209 <tag>glossary</tag> or <tag>glosslist</tag> to specify the
210 width for output of <tag>glossterm</tag> instances in the
211 output.</para>
212</refdescription>
213 <refsynopsisdiv>
214 <synopsis><tag class="xmlpi">dbfo glossterm-width="<replaceable>width</replaceable>"</tag></synopsis>
215 </refsynopsisdiv>
216<refparameter>
217 <variablelist>
218 <varlistentry><term>glossterm-width="<replaceable>width</replaceable>"</term>
219 <listitem>
220 <para>FIXME: Specifies the glossterm width (in what units?)</para>
221 </listitem>
222 </varlistentry>
223 </variablelist>
224</refparameter>
225</doc:pi>
226<xsl:template name="pi.dbfo_glossterm-width">
227 <xsl:param name="node" select="."/>
228 <xsl:call-template name="dbfo-attribute">
229 <xsl:with-param name="pis" select="$node/processing-instruction('dbfo')"/>
230 <xsl:with-param name="attribute" select="'glossterm-width'"/>
231 </xsl:call-template>
232</xsl:template>
233
234<doc:pi name="dbfo_keep-together" xmlns="">
235<refpurpose>Specifies “keep” behavior for a table, example,
236 figure, or equation</refpurpose>
237<refdescription>
238 <para>Use the <tag>dbfo keep-together</tag> PI as a child of a
239 formal object (<tag>table</tag>, <tag>example</tag>,
240 <tag>figure</tag>, or <tag>equation</tag>) or their informal
241 equivalents) to specify “keep” behavior for the object (to
242 allow the object to “break” across a page).</para>
243</refdescription>
244 <refsynopsisdiv>
245 <synopsis><tag class="xmlpi">dbfo keep-together="auto"|"always"</tag></synopsis>
246 </refsynopsisdiv>
247<refparameter>
248 <variablelist>
249 <varlistentry><term>keep-together="auto"</term>
250 <listitem>
251 <para>Enables the object to break across a page</para>
252 </listitem>
253 </varlistentry>
254 <varlistentry><term>keep-together="always"</term>
255 <listitem>
256 <para>Prevents the object from breaking across a page (the
257 default stylesheet behavior)</para>
258 </listitem>
259 </varlistentry>
260 </variablelist>
261</refparameter>
262</doc:pi>
263<xsl:template name="pi.dbfo_keep-together">
264 <xsl:param name="node" select="."/>
265 <xsl:call-template name="dbfo-attribute">
266 <xsl:with-param name="pis" select="$node/processing-instruction('dbfo')"/>
267 <xsl:with-param name="attribute" select="'keep-together'"/>
268 </xsl:call-template>
269</xsl:template>
270
271<doc:pi name="dbfo_label-width" xmlns="">
272<refpurpose>Specifies the label width for an itemizedlist,
273 orderedlist, or qandaset</refpurpose>
274<refdescription>
275 <para>Use the <tag>dbfo label-width</tag> PI as a child of an
276 <tag>itemizedlist</tag>, <tag>orderedlist</tag>, or
277 <tag>qandaset</tag> to specify the width of labels.</para>
278</refdescription>
279 <refsynopsisdiv>
280 <synopsis><tag class="xmlpi">dbfo label-width="<replaceable>width</replaceable>"</tag></synopsis>
281 </refsynopsisdiv>
282<refparameter>
283 <variablelist>
284 <varlistentry><term>label-width="<replaceable>width</replaceable>"</term>
285 <listitem>
286 <para>FIXME: Specifies the label width (in what units?)</para>
287 </listitem>
288 </varlistentry>
289 </variablelist>
290</refparameter>
291</doc:pi>
292<xsl:template name="pi.dbfo_label-width">
293 <xsl:param name="node" select="."/>
294 <xsl:call-template name="dbfo-attribute">
295 <xsl:with-param name="pis" select="$node/processing-instruction('dbfo')"/>
296 <xsl:with-param name="attribute" select="'label-width'"/>
297 </xsl:call-template>
298</xsl:template>
299
300<doc:pi name="dbfo_linenumbering.everyNth" xmlns="">
301<refpurpose>Specifies the interval at which lines are numbered
302 output of verbatim environments</refpurpose>
303<refdescription>
304 <para>Use the <tag>dbfo linenumbering.everyNth</tag> PI as a child
305 of a “verbatim” element – <tag>programlisting</tag>,
306 <tag>screen</tag>, <tag>synopsis</tag> — to specify
307 the interval at which lines are numbered.</para>
308</refdescription>
309 <refsynopsisdiv>
310 <synopsis><tag class="xmlpi">dbfo linenumbering.everyNth="<replaceable>N</replaceable>"</tag></synopsis>
311 </refsynopsisdiv>
312<refparameter>
313 <variablelist>
314 <varlistentry><term>linenumbering.everyNth="<replaceable>N</replaceable>"</term>
315 <listitem>
316 <para>FIXME: Specifies numbering interval; a number is
317 output before every <replaceable>N</replaceable>th line</para>
318 </listitem>
319 </varlistentry>
320 </variablelist>
321</refparameter>
322</doc:pi>
323<xsl:template name="pi.dbfo_linenumbering.everyNth">
324 <xsl:param name="node" select="."/>
325 <xsl:call-template name="dbfo-attribute">
326 <xsl:with-param name="pis"
327 select="$node/processing-instruction('dbfo')"/>
328 <xsl:with-param name="attribute" select="'linenumbering.everyNth'"/>
329 </xsl:call-template>
330</xsl:template>
331
332<doc:pi name="dbfo_linenumbering.separator" xmlns="">
333<refpurpose>Specifies the separator text used between line numbers
334 and content in output of verbatim environments</refpurpose>
335<refdescription>
336 <para>Use the <tag>dbfo linenumbering.separator</tag> PI as a child
337 of a “verbatim” element – <tag>programlisting</tag>,
338 <tag>screen</tag>, <tag>synopsis</tag> — to specify
339 the separator text output between the line numbers and content.</para>
340</refdescription>
341 <refsynopsisdiv>
342 <synopsis><tag class="xmlpi">dbfo linenumbering.separator="<replaceable>text</replaceable>"</tag></synopsis>
343 </refsynopsisdiv>
344<refparameter>
345 <variablelist>
346 <varlistentry><term>linenumbering.separator="<replaceable>text</replaceable>"</term>
347 <listitem>
348 <para>FIXME: Specifies the text (zero or more characters)</para>
349 </listitem>
350 </varlistentry>
351 </variablelist>
352</refparameter>
353</doc:pi>
354<xsl:template name="pi.dbfo_linenumbering.separator">
355 <xsl:param name="node" select="."/>
356 <xsl:call-template name="dbfo-attribute">
357 <xsl:with-param name="pis"
358 select="$node/processing-instruction('dbfo')"/>
359 <xsl:with-param name="attribute" select="'linenumbering.separator'"/>
360 </xsl:call-template>
361</xsl:template>
362
363<doc:pi name="dbfo_linenumbering.width" xmlns="">
364<refpurpose>Specifies the width set aside for line numbers in
365 output of verbatim environments</refpurpose>
366<refdescription>
367 <para>Use the <tag>dbfo linenumbering.width</tag> PI as a child
368 of a “verbatim” element – <tag>programlisting</tag>,
369 <tag>screen</tag>, <tag>synopsis</tag> — to specify
370 the width set aside for line numbers.</para>
371</refdescription>
372 <refsynopsisdiv>
373 <synopsis><tag class="xmlpi">dbfo linenumbering.width="<replaceable>width</replaceable>"</tag></synopsis>
374 </refsynopsisdiv>
375<refparameter>
376 <variablelist>
377 <varlistentry><term>linenumbering.width="<replaceable>width</replaceable>"</term>
378 <listitem>
379 <para>FIXME: Specifies the width (in what units?)</para>
380 </listitem>
381 </varlistentry>
382 </variablelist>
383</refparameter>
384</doc:pi>
385<xsl:template name="pi.dbfo_linenumbering.width">
386 <xsl:param name="node" select="."/>
387 <xsl:call-template name="dbfo-attribute">
388 <xsl:with-param name="pis"
389 select="$node/processing-instruction('dbfo')"/>
390 <xsl:with-param name="attribute" select="'linenumbering.width'"/>
391 </xsl:call-template>
392</xsl:template>
393
394<doc:pi name="dbfo_list-width" xmlns="">
395<refpurpose>Specifies the width of a horizontal simplelist</refpurpose>
396<refdescription>
397 <para>Use the <tag>dbfo list-width</tag> PI as a child of a
398 <tag>simplelist</tag> whose <tag class="attribute">class</tag>
399 value is <literal>horizontal</literal>, to specify the width
400 of the <tag>simplelist</tag>.</para>
401</refdescription>
402 <refsynopsisdiv>
403 <synopsis><tag class="xmlpi">dbfo list-width="<replaceable>width</replaceable>"</tag></synopsis>
404 </refsynopsisdiv>
405<refparameter>
406 <variablelist>
407 <varlistentry><term>list-width="<replaceable>width</replaceable>"</term>
408 <listitem>
409 <para>FIXME: Specifies the <tag>simplelist</tag> width (in what units?)</para>
410 </listitem>
411 </varlistentry>
412 </variablelist>
413</refparameter>
414</doc:pi>
415<xsl:template name="pi.dbfo_list-width">
416 <xsl:param name="node" select="."/>
417 <xsl:call-template name="dbfo-attribute">
418 <xsl:with-param name="pis" select="$node/processing-instruction('dbfo')"/>
419 <xsl:with-param name="attribute" select="'list-width'"/>
420 </xsl:call-template>
421</xsl:template>
422
423<doc:pi name="dbfo_list-presentation" xmlns="">
424<refpurpose>Specifies presentation style for a variablelist or
425 segmentedlist</refpurpose>
426<refdescription>
427 <para>Use the <tag>dbfo list-presentation</tag> PI as a child of
428 a <tag>variablelist</tag> or <tag>segmentedlist</tag> to
429 control the presentation style for the list (to cause it, for
430 example, to be displayed as a table).</para>
431</refdescription>
432 <refsynopsisdiv>
433 <synopsis><tag class="xmlpi">dbfo list-presentation="list"|"blocks"|"table"</tag></synopsis>
434 </refsynopsisdiv>
435<refparameter>
436 <variablelist>
437 <varlistentry><term>list-presentation="list"</term>
438 <listitem>
439 <para>Displayed the list as a list</para>
440 </listitem>
441 </varlistentry>
442 <varlistentry><term>list-presentation="blocks"</term>
443 <listitem>
444 <para>(<tag>variablelist</tag> only) Displays the list as blocks</para>
445 </listitem>
446 </varlistentry>
447 <varlistentry><term>list-presentation="table"</term>
448 <listitem>
449 <para>(<tag>segmentedlist</tag> only) Displays the list as a table</para>
450 </listitem>
451 </varlistentry>
452 </variablelist>
453</refparameter>
454</doc:pi>
455<xsl:template name="pi.dbfo_list-presentation">
456 <xsl:param name="node" select="."/>
457 <xsl:call-template name="dbfo-attribute">
458 <xsl:with-param name="pis" select="$node/processing-instruction('dbfo')"/>
459 <xsl:with-param name="attribute" select="'list-presentation'"/>
460 </xsl:call-template>
461</xsl:template>
462
463<doc:pi name="dbfo_orientation" xmlns="">
464<refpurpose>Specifies the orientation for table row or cell</refpurpose>
465<refdescription>
466 <para>Use the <tag>dbfo orientation</tag> PI as a child of an
467 <tag>table</tag> row or cell to specify the orientation
468 (rotation) for the row or cell.</para>
469</refdescription>
470 <refsynopsisdiv>
471 <synopsis><tag class="xmlpi">dbfo orientation="0"|"90"|"180"|"270"|"-90"|"-180"|"-270"</tag></synopsis>
472 </refsynopsisdiv>
473<refparameter>
474 <variablelist>
475 <varlistentry><term>orientation="0"|"90"|"180"|"270"|"-90"|"-180"|"-270"</term>
476 <listitem>
477 <para>Specifies the number of degrees by which the cell or
478 row is rotated</para>
479 </listitem>
480 </varlistentry>
481 </variablelist>
482</refparameter>
483</doc:pi>
484<xsl:template name="pi.dbfo_orientation">
485 <xsl:param name="node" select="."/>
486 <xsl:call-template name="dbfo-attribute">
487 <xsl:with-param name="pis" select="$node/processing-instruction('dbfo')"/>
488 <xsl:with-param name="attribute" select="'orientation'"/>
489 </xsl:call-template>
490</xsl:template>
491
492<doc:pi name="dbfo_pgwide" xmlns="">
493 <refpurpose>Species whether an <tag>equation</tag> or
494 <tag>example</tag> should rendered across the full width of a
495 page</refpurpose>
496<refdescription>
497 <para>Use the <tag>dbfo pgwide</tag> PI as a child of an
498 <tag>equation</tag> or <tag>example</tag> to specify that the
499 content should rendered across the full width of the page.</para>
500</refdescription>
501 <refsynopsisdiv>
502 <synopsis><tag class="xmlpi">dbfo pgwide="0"|"1"</tag></synopsis>
503 </refsynopsisdiv>
504<refparameter>
505 <variablelist>
506 <varlistentry><term>pgwide="0"</term>
507 <listitem>
508 <para>If zero, the content is rendered across the current
509 text flow</para>
510 </listitem>
511 </varlistentry>
512 <varlistentry><term>pgwide="1"</term>
513 <listitem>
514 <para>If <code>1</code> (or any non-zero value), the
515 content is rendered across the full width of the page</para>
516 </listitem>
517 </varlistentry>
518 </variablelist>
519</refparameter>
520</doc:pi>
521<xsl:template name="pi.dbfo_pgwide">
522 <xsl:param name="node" select="."/>
523 <xsl:call-template name="dbfo-attribute">
524 <xsl:with-param name="pis" select="$node/processing-instruction('dbfo')"/>
525 <xsl:with-param name="attribute" select="'pgwide'"/>
526 </xsl:call-template>
527</xsl:template>
528
529<doc:pi name="dbfo_rotated-width" xmlns="">
530 <refpurpose>Specifies the width for a table <tag>entry</tag> or
531 <tag>row</tag></refpurpose>
532<refdescription>
533 <para>Use the <tag>dbfo rotated-width</tag> PI as a child of an
534 <tag>entry</tag> or <tag>row</tag> instance to specify the
535 width of that the <tag>entry</tag> or <tag>row</tag>; or
536 use it higher up in table to cause the width to be inherited
537 recursively down.</para>
538</refdescription>
539 <refsynopsisdiv>
540 <synopsis><tag class="xmlpi">dbfo rotated-width="<replaceable>width</replaceable>"</tag></synopsis>
541 </refsynopsisdiv>
542<refparameter>
543 <variablelist>
544 <varlistentry><term>rotated-width="<replaceable>width</replaceable>"</term>
545 <listitem>
546 <para>FIXME: Specifies the width of a row or cell (in what units?)</para>
547 </listitem>
548 </varlistentry>
549 </variablelist>
550</refparameter>
551</doc:pi>
552<xsl:template name="pi.dbfo_rotated-width">
553 <xsl:param name="node" select="."/>
554 <xsl:call-template name="dbfo-attribute">
555 <xsl:with-param name="pis"
556 select="$node/processing-instruction('dbfo')"/>
557 <xsl:with-param name="attribute" select="'rotated-width'"/>
558 </xsl:call-template>
559</xsl:template>
560
561<doc:pi name="dbfo_sidebar-width" xmlns="">
562<refpurpose>Specifies the width of a sidebar</refpurpose>
563<refdescription>
564 <para>Use the <tag>dbfo sidebar-width</tag> PI as a child of a
565 <tag>sidebar</tag> to specify the width of the sidebar.</para>
566</refdescription>
567 <refsynopsisdiv>
568 <synopsis><tag class="xmlpi">dbfo sidebar-width="<replaceable>width</replaceable>"</tag></synopsis>
569 </refsynopsisdiv>
570<refparameter>
571 <variablelist>
572 <varlistentry><term>sidebar-width="<replaceable>width</replaceable>"</term>
573 <listitem>
574 <para>FIXME: Specifies the <tag>sidebar</tag> width (in what units?)</para>
575 </listitem>
576 </varlistentry>
577 </variablelist>
578</refparameter>
579</doc:pi>
580<xsl:template name="pi.dbfo_sidebar-width">
581 <xsl:param name="node" select="."/>
582 <xsl:call-template name="dbfo-attribute">
583 <xsl:with-param name="pis" select="$node/processing-instruction('dbfo')"/>
584 <xsl:with-param name="attribute" select="'sidebar-width'"/>
585 </xsl:call-template>
586</xsl:template>
587
588<doc:pi name="dbfo_table-width" xmlns="">
589<refpurpose>Specifies the width for a table or for revhistory
590 output</refpurpose>
591<refdescription>
592 <para>Use the <tag>dbfo table-width</tag> PI as a child of a
593 <tag>table</tag> or <tag>revhistory</tag> instance (which is
594 rendered as a table in output) to specify the width of the
595 table in output.</para>
596</refdescription>
597 <refsynopsisdiv>
598 <synopsis><tag class="xmlpi">dbfo table-width="<replaceable>width</replaceable>"</tag></synopsis>
599 </refsynopsisdiv>
600<refparameter>
601 <variablelist>
602 <varlistentry><term>table-width="<replaceable>width</replaceable>"</term>
603 <listitem>
604 <para>FIXME: Specifies the table width (in what units?)</para>
605 </listitem>
606 </varlistentry>
607 </variablelist>
608</refparameter>
609</doc:pi>
610<xsl:template name="pi.dbfo_table-width">
611 <xsl:param name="node" select="."/>
612 <xsl:call-template name="dbfo-attribute">
613 <xsl:with-param name="pis" select="$node/processing-instruction('dbfo')"/>
614 <xsl:with-param name="attribute" select="'table-width'"/>
615 </xsl:call-template>
616</xsl:template>
617
618<doc:pi name="dbfo_term-width" xmlns="">
619<refpurpose>Specifies the term width for a variablelist</refpurpose>
620<refdescription>
621 <para>Use the <tag>dbfo term-width</tag> PI as a child of a
622 <tag>variablelist</tag> to specify the width for
623 <tag>term</tag> output.</para>
624</refdescription>
625 <refsynopsisdiv>
626 <synopsis><tag class="xmlpi">dbfo term-width="<replaceable>width</replaceable>"</tag></synopsis>
627 </refsynopsisdiv>
628<refparameter>
629 <variablelist>
630 <varlistentry><term>term-width="<replaceable>width</replaceable>"</term>
631 <listitem>
632 <para>FIXME: Specifies the term width (in what units?)</para>
633 </listitem>
634 </varlistentry>
635 </variablelist>
636</refparameter>
637</doc:pi>
638<xsl:template name="pi.dbfo_term-width">
639 <xsl:param name="node" select="."/>
640 <xsl:call-template name="dbfo-attribute">
641 <xsl:with-param name="pis" select="$node/processing-instruction('dbfo')"/>
642 <xsl:with-param name="attribute" select="'term-width'"/>
643 </xsl:call-template>
644</xsl:template>
645
646<doc:pi name="dbfo_toc" xmlns="">
647<refpurpose>Species whether a TOC should be generated for a qandaset</refpurpose>
648<refdescription>
649 <para>Use the <tag>dbfo toc</tag> PI as a child of a
650 <tag>jandaset</tag> to specify whether a table of contents
651 (TOC) is generated for the <tag>qandaset</tag>.</para>
652</refdescription>
653 <refsynopsisdiv>
654 <synopsis><tag class="xmlpi">dbfo toc="0"|"1"</tag></synopsis>
655 </refsynopsisdiv>
656<refparameter>
657 <variablelist>
658 <varlistentry><term>toc="0"</term>
659 <listitem>
660 <para>If zero, no TOC is generated</para>
661 </listitem>
662 </varlistentry>
663 <varlistentry><term>toc="1"</term>
664 <listitem>
665 <para>If <code>1</code> (or any non-zero value),
666 a TOC is generated</para>
667 </listitem>
668 </varlistentry>
669 </variablelist>
670</refparameter>
671</doc:pi>
672<xsl:template name="pi.dbfo_toc">
673 <xsl:param name="node" select="."/>
674 <xsl:call-template name="dbfo-attribute">
675 <xsl:with-param name="pis" select="$node/processing-instruction('dbfo')"/>
676 <xsl:with-param name="attribute" select="'toc'"/>
677 </xsl:call-template>
678</xsl:template>
679
680<!-- ==================================================================== -->
681
682<doc:pi name="dbfo-need" xmlns="">
683<refpurpose>Specify a need for space (a kind of soft page break)</refpurpose>
684<refdescription>
685 <para>A “need” is a request for space on a page. If the
686 requested space is not available, the page breaks and the
687 content that follows the need request appears on the next
688 page. If the requested space is available, then the request is
689 ignored.</para>
690</refdescription>
691 <refsynopsisdiv>
692 <synopsis><tag class="xmlpi">dbfo-need height="<replaceable>n</replaceable>"</tag></synopsis>
693 <synopsis><tag class="xmlpi">dbfo-need space-before="<replaceable>n</replaceable>"</tag></synopsis>
694 </refsynopsisdiv>
695<refparameter>
696 <variablelist>
697 <varlistentry><term>height="<replaceable>n</replaceable>"</term>
698 <listitem>
699 <para>FIXME: the amount of height(?) needed? In what units? pt?.</para>
700 </listitem>
701 </varlistentry>
702 <varlistentry><term>space-before"<replaceable>n</replaceable>"</term>
703 <listitem>
704 <para>FIXME: the amount of space needed before the
705 [something]? In what units? pt?.</para>
706 </listitem>
707 </varlistentry>
708 </variablelist>
709</refparameter>
710</doc:pi>
711<xsl:template name="pi.dbfo-need">
712 <xsl:variable name="pi-height">
713 <xsl:call-template name="dbfo-attribute">
714 <xsl:with-param name="pis" select="."/>
715 <xsl:with-param name="attribute" select="'height'"/>
716 </xsl:call-template>
717 </xsl:variable>
718
719 <xsl:variable name="height">
720 <xsl:choose>
721 <xsl:when test="$pi-height != ''">
722 <xsl:value-of select="$pi-height"/>
723 </xsl:when>
724 <xsl:otherwise>0pt</xsl:otherwise>
725 </xsl:choose>
726 </xsl:variable>
727
728 <xsl:variable name="pi-before">
729 <xsl:call-template name="dbfo-attribute">
730 <xsl:with-param name="pis" select="."/>
731 <xsl:with-param name="attribute" select="'space-before'"/>
732 </xsl:call-template>
733 </xsl:variable>
734
735 <xsl:variable name="spacer">
736 <fo:block-container width="100%" height="{$height}">
737 <fo:block><fo:leader leader-length="0pt"/></fo:block>
738 </fo:block-container>
739 </xsl:variable>
740
741 <xsl:choose>
742 <xsl:when test="$fop.extensions != 0">
743 <!-- Doesn't work in fop -->
744 </xsl:when>
745 <xsl:when test="$pi-before != '' and
746 not(following-sibling::listitem) and
747 not(following-sibling::step)">
748 <fo:block space-after="0pt" space-before="{$pi-before}">
749 <xsl:copy-of select="$spacer"/>
750 </fo:block>
751 </xsl:when>
752 <xsl:when test="following-sibling::para">
753 <fo:block space-after="0pt"
754 xsl:use-attribute-sets="normal.para.spacing">
755 <xsl:copy-of select="$spacer"/>
756 </fo:block>
757 </xsl:when>
758 <xsl:when test="following-sibling::table or
759 following-sibling::figure or
760 following-sibling::example or
761 following-sibling::equation">
762 <fo:block space-after="0pt"
763 xsl:use-attribute-sets="formal.object.properties">
764 <xsl:copy-of select="$spacer"/>
765 </fo:block>
766 </xsl:when>
767 <xsl:when test="following-sibling::informaltable or
768 following-sibling::informalfigure or
769 following-sibling::informalexample or
770 following-sibling::informalequation">
771 <fo:block space-after="0pt"
772 xsl:use-attribute-sets="informal.object.properties">
773 <xsl:copy-of select="$spacer"/>
774 </fo:block>
775 </xsl:when>
776 <xsl:when test="following-sibling::itemizedlist or
777 following-sibling::orderedlist or
778 following-sibling::variablelist or
779 following-sibling::simplelist">
780 <fo:block space-after="0pt"
781 xsl:use-attribute-sets="informal.object.properties">
782 <xsl:copy-of select="$spacer"/>
783 </fo:block>
784 </xsl:when>
785 <xsl:when test="following-sibling::listitem or
786 following-sibling::step">
787 <fo:list-item space-after="0pt"
788 xsl:use-attribute-sets="informal.object.properties">
789 <fo:list-item-label/>
790 <fo:list-item-body start-indent="0pt" end-indent="0pt">
791 <xsl:copy-of select="$spacer"/>
792 </fo:list-item-body>
793 </fo:list-item>
794 </xsl:when>
795 <xsl:when test="following-sibling::sect1 or
796 following-sibling::sect2 or
797 following-sibling::sect3 or
798 following-sibling::sect4 or
799 following-sibling::sect5 or
800 following-sibling::section">
801 <fo:block space-after="0pt"
802 xsl:use-attribute-sets="section.title.properties">
803 <xsl:copy-of select="$spacer"/>
804 </fo:block>
805 </xsl:when>
806 <xsl:otherwise>
807 <fo:block space-after="0pt" space-before="0em">
808 <xsl:copy-of select="$spacer"/>
809 </fo:block>
810 </xsl:otherwise>
811 </xsl:choose>
812
813 <xsl:choose>
814 <xsl:when test="$fop.extensions != 0">
815 <!-- Doesn't work in fop -->
816 </xsl:when>
817 <xsl:when test="following-sibling::listitem or
818 following-sibling::step">
819 <fo:list-item space-before.precedence="force"
820 space-before="-{$height}"
821 space-after="0pt"
822 space-after.precedence="force">
823 <fo:list-item-label/>
824 <fo:list-item-body start-indent="0pt" end-indent="0pt"/>
825 </fo:list-item>
826 </xsl:when>
827 <xsl:otherwise>
828 <fo:block space-before.precedence="force"
829 space-before="-{$height}"
830 space-after="0pt"
831 space-after.precedence="force">
832 </fo:block>
833 </xsl:otherwise>
834 </xsl:choose>
835</xsl:template>
836
837<!-- ==================================================================== -->
838
839<xsl:template name="dbfo-attribute">
840 <!-- * dbfo-attribute is an interal utility template for retrieving -->
841 <!-- * pseudo-attributes/parameters from PIs -->
842 <xsl:param name="pis" select="processing-instruction('dbfo')"/>
843 <xsl:param name="attribute">filename</xsl:param>
844 <xsl:call-template name="pi-attribute">
845 <xsl:with-param name="pis" select="$pis"/>
846 <xsl:with-param name="attribute" select="$attribute"/>
847 </xsl:call-template>
848</xsl:template>
849
850<!-- ==================================================================== -->
851<xsl:template match="processing-instruction()">
852</xsl:template>
853
854<!-- ==================================================================== -->
855
856<xsl:template match="processing-instruction('dbfo-need')">
857 <xsl:call-template name="pi.dbfo-need"/>
858</xsl:template>
859
860</xsl:stylesheet>
Note: See TracBrowser for help on using the repository browser.