The chapter structuring commands divide a document into a hierarchy of chapters, sections, subsections, and subsubsections. These commands generate large headings; they also provide information for the table of contents of a printed manual (see section Generating a Table of Contents).
The chapter structuring commands do not create an Info node structure,
so normally you should put an
@node command immediately before
each chapter structuring command (see section Nodes). The only time you
are likely to use the chapter structuring commands without using the
node structuring commands is if you are writing a document that
contains no cross references and will never be transformed into Info
It is unlikely that you will ever write a Texinfo file that is intended only as an Info file and not as a printable document. If you do, you might still use chapter structuring commands to create a heading at the top of each node--but you don't need to.
@topcommand, part of the `Top' node.
A Texinfo file is usually structured like a book with chapters, sections, subsections, and the like. This structure can be visualized as a tree (or rather as an upside-down tree) with the root at the top and the levels corresponding to chapters, sections, subsection, and subsubsections.
Here is a diagram that shows a Texinfo file with three chapters, each of which has two sections.
Top | ------------------------------------- | | | Chapter 1 Chapter 2 Chapter 3 | | | -------- -------- -------- | | | | | | Section Section Section Section Section Section 1.1 1.2 2.1 2.2 3.1 3.2
In a Texinfo file that has this structure, the beginning of Chapter 2 looks like this:
@node Chapter 2, Chapter 3, Chapter 1, top @chapter Chapter 2
The chapter structuring commands are described in the sections that
@menu commands are described in
following chapters. (See section Nodes, and see section Menus.)
The chapter structuring commands fall into four groups or series, each of which contains structuring commands corresponding to the hierarchical levels of chapters, sections, subsections, and subsubsections.
The four groups are the
@chapter series, the
@unnumbered series, the
@appendix series, and the
Each command produces titles that have a different appearance on the printed page or Info file; only some of the commands produce titles that are listed in the table of contents of a printed book or manual.
@appendixseries of commands produce numbered or lettered entries both in the body of a printed work and in its table of contents.
@unnumberedseries of commands produce unnumbered entries both in the body of a printed work and in its table of contents. The
@topcommand, which has a special use, is a member of this series (see section
@headingseries of commands produce unnumbered headings that do not appear in a table of contents. The heading commands never start a new page.
@majorheadingcommand produces results similar to using the
@chapheadingcommand but generates a larger vertical whitespace before the heading.
@setchapternewpagecommand says to do so, the
@appendixcommands start new pages in the printed manual; the
@headingcommands do not.
Here are the four groups of chapter structuring commands:
@top command is a special sectioning command that you use
only after an
@node Top line at the beginning of a Texinfo file.
@top command tells the
which node is the `Top'
node. It has the same typesetting effect as
For detailed information, see
@top Sectioning Command.
@chapter identifies a chapter in the document. Write the
command at the beginning of a line and follow it on the same line by
the title of the chapter.
For example, this chapter in this manual is entitled "Chapter
@chapter line looks like this:
@chapter Chapter Structuring
In TeX, the
@chapter command creates a chapter in the
document, specifying the chapter title. The chapter is numbered
In Info, the
@chapter command causes the title to appear on a
line by itself, with a line of asterisks inserted underneath. Thus,
in Info, the above example produces the following output:
Chapter Structuring *******************
@unnumbered command to create a chapter that appears
in a printed manual without chapter numbers of any kind. Use the
@appendix command to create an appendix in a printed manual
that is labelled by letter instead of by number.
For Info file output, the
commands are equivalent to
@chapter: the title is printed on a
line by itself with a line of asterisks underneath. (See section
To create an appendix or an unnumbered chapter, write an
@unnumbered command at the beginning of a
line and follow it on the same line by the title, as you would if you
were creating a chapter.
@chapheading commands put
chapter-like headings in the body of a document.
However, neither command causes TeX to produce a numbered heading or an entry in the table of contents; and neither command causes TeX to start a new page in a printed manual.
In TeX, an
@majorheading command generates a larger vertical
whitespace before the heading than an
@chapheading command but
is otherwise the same.
@chapheading commands are equivalent to
@chapter: the title is printed on a line by itself with a line
of asterisks underneath. (See section
In a printed manual, an
@section command identifies a
numbered section within a chapter. The section title appears in the
table of contents. In Info, an
@section command provides a
title for a segment of text, underlined with `='.
This section is headed with an
@section command and looks like
this in the Texinfo file:
To create a section, write the
@section command at the
beginning of a line and follow it on the same line by the section
@section This is a section
This is a section =================
commands are, respectively, the unnumbered, appendix-like, and
heading-like equivalents of the
@unnumberedseccommand may be used within an unnumbered chapter or within a regular chapter or appendix to provide an unnumbered section.
@appendixsectionis a longer spelling of the
@appendixseccommand; the two are synonymous. Conventionally, the
@appendixsectioncommand is used only within appendices.
@headingcommand anywhere you wish for a section-style heading that will not appear in the table of contents.
Subsections are to sections as sections are to chapters.
@section.) In Info, subsection titles are
underlined with `-'. For example,
@subsection This is a subsection
This is a subsection --------------------
In a printed manual, subsections are listed in the table of contents and are numbered three levels deep.
@subheading commands are, respectively, the unnumbered,
appendix-like, and heading-like equivalents of the
command. (See section The
In Info, the
@subsection-like commands generate a title
underlined with hyphens. In a printed manual, an
command produces a heading like that of a subsection except that it is
not numbered and does not appear in the table of contents. Similarly,
@unnumberedsubsec command produces an unnumbered heading like
that of a subsection and an
@appendixsubsec command produces a
subsection-like heading labelled with a letter and numbers; both of
these commands produce headings that appear in the table of
The fourth and lowest level sectioning commands in Texinfo are the `subsub' commands. They are:
@subsectionCommand.) In a printed manual, subsubsection titles appear in the table of contents and are numbered four levels deep.
@subsubheadingcommand may be used anywhere that you need a small heading that will not appear in the table of contents. In Info, subsubheadings look exactly like ordinary subsubsection headings.
In Info, `subsub' titles are underlined with periods. For example,
@subsubsection This is a subsubsection
This is a subsubsection .......................
@lowersections commands raise and
lower the hierarchical level of chapters, sections, subsections and the
@raisesections command changes sections to chapters,
subsections to sections, and so on. The
changes chapters to sections, sections to subsections, and so on.
@lowersections command is useful if you wish to include text
that is written as an outer or standalone Texinfo file in another
Texinfo file as an inner, included file. If you write the command at
the beginning of the file, all your
@chapter commands are
formatted as if they were
@section commands, all your
@section command are formatted as if they were
@subsection commands, and so on.
@raisesections raises a command one level in the chapter
Change To @subsection @section, @section @chapter, @heading @chapheading, etc.
@lowersections lowers a command one level in the chapter
Change To @chapter @section, @subsection @subsubsection, @heading @subheading, etc.
@lowersections command changes only
those structuring commands that follow the command in the Texinfo file.
@lowersections command on a
line of its own.
@lowersections command cancels an
command, and vice versa.
Repeated use of the commands continue to raise or lower the hierarchical level a step at a time.
An attempt to raise above `chapters' reproduces chapter commands; an attempt to lower below `subsubsections' reproduces subsubsection commands.