The chapter structuring commands fall into four groups, each of which contains structuring commands at the levels of chapters, sections, subsections, and subsubsections:
@chapter
-like commands and @appendix
-like commands
produce numbered or lettered entries both in the body of a document and
in its table of contents.
@unnumbered
-like commands produce unnumbered entries
both in the body of a document and in its table of contents. The
@top
command, which has a special use, is a member of this
group (see The @top
Sectioning Command). An @unnumbered
section
is a normal part of the document structure.
@heading
-like commands produce simple unnumbered
headings that do not appear in a table of contents, are not associated
with nodes, and cannot be cross-referenced. These heading commands
never start a new page.
In printed output, the chapter structuring commands produce headings
in the document. When a @setchapternewpage
command says to do so, the
@chapter
, @unnumbered
, and @appendix
commands
start new pages in the printed manual; the @heading
commands
do not. See @setchapternewpage
: Blank Pages Before Chapters.
In Info and plain text output, the command causes the title to appear on a line by itself, with a line of an ASCII character (‘*’, ‘=’, …) inserted underneath. For example, the “Chapter Structuring” heading could be:
5 Chapter Structuring *********************
The underlining character is the same for all the commands at the
same level. For instance, it is the same for the chapter-level commands
@chapter
, @apppendix
, @unnumbered
and
@chapheading
.
In HTML, the chapter-level commands produce an <h2>
-level
header by default (controlled by the CHAPTER_HEADER_LEVEL
customization variable, see Other Customization Variables).
The heading element level is adjusted for the other commands.
In the DocBook output, the appropriate level of element is used.
The produced element includes all following sections up to the next command
at the same or higher level.
For example, a <chapter>
element is produced for @chapter
,
and contains any sections or subsections in the chapter.
Here is a summary:
No new page | |||
Numbered | Unnumbered | Lettered/numbered | Unnumbered |
In contents | In contents | In contents | Not in contents |
@top | @majorheading | ||
@chapter | @unnumbered | @appendix | @chapheading |
@section | @unnumberedsec | @appendixsec | @heading |
@subsection | @unnumberedsubsec | @appendixsubsec | @subheading |
@subsubsection | @unnumberedsubsubsec | @appendixsubsubsec | @subsubheading |