File: generate.toc.html

package info (click to toggle)
docbook-xsl-doc 1.78.1-1.1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 6,848 kB
  • sloc: makefile: 10; sh: 5
file content (83 lines) | stat: -rw-r--r-- 5,217 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
<html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>generate.toc</title><link rel="stylesheet" type="text/css" href="../reference.css"><meta name="generator" content="DocBook XSL Stylesheets V1.78.1"><link rel="home" href="../index.html" title="DocBook XSL Stylesheets: ReferenceDocumentation"><link rel="up" href="toc_index.html" title="ToC/LoT/Index Generation"><link rel="prev" href="process.source.toc.html" title="process.source.toc"><link rel="next" href="generate.index.html" title="generate.index"><link rel="copyright" href="copyright.html" title="License"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">generate.toc</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="process.source.toc.html">Prev</a></td><th width="60%" align="center">ToC/LoT/Index Generation</th><td width="20%" align="right"><a accesskey="n" href="generate.index.html">Next</a></td></tr></table><hr></div><div class="refentry"><a name="generate.toc"></a><div class="titlepage"></div>

<div class="refnamediv"><h2><span class="refentrytitle">generate.toc</span></h2><p>
generate.toc
 &#8212; Control generation of ToCs and LoTs
</p></div>

<div class="refsynopsisdiv"><h2>Synopsis</h2>
<a name="generate.toc.frag"></a><pre class="programlisting">

&lt;xsl:param name="generate.toc"&gt;
/appendix toc,title
article/appendix  nop
/article  toc,title
book      toc,title,figure,table,example,equation
/chapter  toc,title
part      toc,title
/preface  toc,title
reference toc,title
/sect1    toc
/sect2    toc
/sect3    toc
/sect4    toc
/sect5    toc
/section  toc
set       toc,title
&lt;/xsl:param&gt;
</pre>
</div>

<div class="refsection"><a name="idp3500736"></a><h2>Description</h2>

<p>This parameter has a structured value. It is a table of space-delimited
path/value pairs. Each path identifies some element in the source document
using a restricted subset of XPath (only the implicit child axis, no wildcards,
no predicates). Paths can be either relative or absolute.</p>

<p>When processing a particular element, the stylesheets consult this table to
determine if a ToC (or LoT(s)) should be generated.</p>

<p>For example, consider the entry:</p>

<pre class="screen">book toc,figure</pre>

<p>This indicates that whenever a <a href="http://docbook.org/tdg5/en/html/book.html"><code class="sgmltag-element">book</code></a> is formatted, a
Table Of Contents and a List of Figures should be generated. Similarly,</p>

<pre class="screen">/chapter toc</pre>

<p>indicates that whenever a document <span class="emphasis"><em>that has a root
of</em></span> <a href="http://docbook.org/tdg5/en/html/chapter.html"><code class="sgmltag-element">chapter</code></a> is formatted, a Table of
Contents should be generated. The entry <code class="literal">chapter</code> would match
all chapters, but <code class="literal">/chapter</code> matches only <a href="http://docbook.org/tdg5/en/html/chapter.html"><code class="sgmltag-element">chapter</code></a>
document elements.</p>

<p>Generally, the longest match wins. So, for example, if you want to distinguish
articles in books from articles in parts, you could use these two entries:</p>

<pre class="screen">book/article toc,figure
part/article toc</pre>

<p>Note that an article in a part can never match a <code class="literal">book/article</code>,
so if you want nothing to be generated for articles in parts, you can simply leave
that rule out.</p>

<p>If you want to leave the rule in, to make it explicit that you're turning
something off, use the value <span class="quote">&#8220;<span class="quote">nop</span>&#8221;</span>. For example, the following
entry disables ToCs and LoTs for articles:</p>

<pre class="screen">article nop</pre>

<p>Do not simply leave the word <span class="quote">&#8220;<span class="quote">article</span>&#8221;</span> in the file
without a matching value. That'd be just begging the silly little
path/value parser to get confused.</p>

<p>Section ToCs are further controlled by the
<a href="../html/generate.section.toc.level.html"><em class="parameter"><code>generate.section.toc.level</code></em></a> parameter.
For a given section level to have a ToC, it must have both an entry in 
<a href="../html/generate.toc.html"><em class="parameter"><code>generate.toc</code></em></a> and be within the range enabled by
<a href="../html/generate.section.toc.level.html"><em class="parameter"><code>generate.section.toc.level</code></em></a>.</p>
</div>
</div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="process.source.toc.html">Prev</a></td><td width="20%" align="center"><a accesskey="u" href="toc_index.html">Up</a></td><td width="40%" align="right"><a accesskey="n" href="generate.index.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">process.source.toc</td><td width="20%" align="center"><a accesskey="h" href="../index.html">Home</a></td><td width="40%" align="right" valign="top">generate.index</td></tr></table></div></body></html>