Go to the first, previous, next, last section, table of contents.

Generating a Table of Contents

The @chapter, @section, and other structuring commands supply the information to make up a table of contents, but they do not cause an actual table to appear in the manual. To do this, you must use the @contents and @summarycontents commands:

@contents
Generate a table of contents in a printed manual, including all chapters, sections, subsections, etc., as well as appendices and unnumbered chapters. (Headings generated by the @heading series of commands do not appear in the table of contents.) The @contents command should be written on a line by itself.
@shortcontents
@summarycontents
(@summarycontents is a synonym for @shortcontents; the two commands are exactly the same.) Generate a short or summary table of contents that lists only the chapters (and appendices and unnumbered chapters). Omit sections, subsections and subsubsections. Only a long manual needs a short table of contents in addition to the full table of contents. Write the @shortcontents command on a line by itself right before the @contents command.

The table of contents commands automatically generate a chapter-like heading at the top of the first table of contents page. Write the table of contents commands at the very end of a Texinfo file, just before the @bye command, following any index sections--anything in the Texinfo file after the table of contents commands will be omitted from the table of contents.

When you print a manual with a table of contents, the table of contents are printed last and numbered with roman numerals. You need to place those pages in their proper place, after the title page, yourself. (This is the only collating you need to do for a printed manual. The table of contents is printed last because it is generated after the rest of the manual is typeset.)

Here is an example of where to write table of contents commands:

indices...
@shortcontents
@contents
@bye

Since an Info file uses menus instead of tables of contents, the Info formatting commands ignore the @contents and @shortcontents commands.


Go to the first, previous, next, last section, table of contents.