Chapter and Section numbering
Depth of Section numbering and Table Of Content Dblatex relies on latex to automatically compute the chapter and section numbers. It also relies on latex to produce the headings with these numbers, and to produce the Table Of Content containing these entries. Some specific sections like preface, colophon, or dedication are not numbered because they are displayed in front and back matters, but they can be listed in the TOC if the related parameters are set (dedication.tocdepth, preface.tocdepth, colophon.tocdepth). More generally you can configure the depth of the chapter and section numbering with the parameter doc.section.depth, and the depth of the entries in the TOC with the parameter toc.section.depth. Note however that an unumbered section becomes an informal component, and therefore you can only link to such a section by using a specific xrefstyle because their label built with the automatic number does not exist anymore. The other drawback is that all the sections included in an unnumbered section or chapter are unnumbered.
Using the latex style for section numbering A well customized latex style can be a powerfull yet versatile alternative to the use of section and/or TOC depth parameter. With some latex packages you can easily format the headings to remove the numbers, or transform them. See to know how to use your own latex style with dblatex. The benefit of this method is that you can fully control how the titles must be displayed, you do not have to play with latex counters to have the right depth, and the sections do not lost their formal number label. The following example shows how you can customize the chapter title by using the latex package titlesec, and shows how to remove the chapter label in the Table Of Content with the package titletoc. Look in particular in the listing where text is emphasized. " \newcommand\makeletterof[1]{% \ifthenelse{\equal{#1}{1}}{ONE}{% \ifthenelse{\equal{#1}{2}}{TWO}{% \ifthenelse{\equal{#1}{3}}{THREE}{% \ifthenelse{\equal{#1}{4}}{FOUR}{% \ifthenelse{\equal{#1}{5}}{FIVE}{% \ifthenelse{\equal{#1}{6}}{SIX}{% \ifthenelse{\equal{#1}{7}}{SEVEN}{% \ifthenelse{\equal{#1}{8}}{EIGHT}{% \ifthenelse{\equal{#1}{9}}{NINE}{% \ifthenelse{\equal{#1}{10}}{TEN}{% \ifthenelse{\equal{#1}{11}}{ELEVEN}{% \ifthenelse{\equal{#1}{12}}{TWELVE}{% #1}}}}}}}}}}}}} \titleformat{\chapter}[block] {\filcenter\ttfamily\huge}% {]]>
Using the <sgmltag>label</sgmltag> attribute If you need to mix numbered and not numbered chapters, the numbering depth parameters will not help. The latex style will not easily detect that for some chapters the number should be displayed and for others it should not. To mix numbered and unnumbered chapters you can use a label with an empty string for the chapters that must not be numbered, as shown by the example below. label=""Introduction label=""Pre-requisite First chapter ... label=""Conclusion ... ]]> You can also set a label to a specific integer to force a section counter. In this case there is no more automatic numbering. The automatic numbering then applies to the following sections that increment the counter set for this section if there is no label. label="2"Introduction
label="3"Section 2.3
label="4"Section 2.3.4
]]>