There are several parameters that control numbering of part, chapter and section titles. By default in printed output, part and chapter titles are numbered but section titles are not. Appendix titles are numbered (with letters) when in a book, but not numbered by default when in an article. In the DocBook XSL stylesheets, the number used in a title is called a label.
The print stylesheet provides an identical set of parameters with
autolabel in the name as in the HTML stylesheets. For a description of how to use such parameters for turning off numbering or changing the numbering style, see the section “Chapter and section numbering” in .
You may want to limit the depth of sections that get a section number. If you have deeply nested sections, then the string of numbers in the section label can get quite long. Or perhaps you just want sections at levels 1 and 2 to be numbered, since any lower level sections are not important enough to have a number label.
You can use the
section.autolabel.max.depth parameter to control which section levels get a number
label. If you set the parameter to 2, then only sections at levels 1
and 2 will have the label. The default value is 8, meaning all
section levels have numbering (if it is turned on).
When producing a book, it is sometimes appropriate to group related chapters into book parts. To do that, you use
part elements in your
book element, and then put your
chapter elements inside your
part elements. Each part has a title, and may have a title page to indicate a new grouping of chapters.
Regardless of whether parts are numbered, you can restart chapter numbering at the beginning of each part. If you want that type of chapter numbering, set the
label.from.part parameter to 1. If you use that option,
you will probably also want to set the
component.label.includes.part.label parameter to 1. That changes the chapter
numbering so the chapters in the first part are numbered I.1, I.2,
I.3, etc., and the chapters in the second part are numbered II.1,
II.2, II.3, etc. If you do not set the second parameter, then your
output will have more than one “Chapter 1” and citations and cross references will be ambiguous. The
parameter similarly modifies appendix numbers.
If you would rather number your parts using arabic numerals instead of uppercase roman numerals, you can put the number format in the parameter value.
This works for the other autolabel parameters as well.
|DocBook XSL: The Complete Guide - 4th Edition||PDF version available|
Copyright © 2002-2007 Sagehill Enterprises