You can use the updating commands to:
You can also use the commands to update all the nodes and menus in a region or in a whole Texinfo file.
The updating commands work only with conventional Texinfo files, which
are structured hierarchically like books. In such files, a structuring
command line must follow closely after each
@node line, except
for the ‘Top’
@node line. (A structuring command line is
a line beginning with
@section, or other
You can write the structuring command line on the line that follows
immediately after an
@node line or else on the line that
follows after a single
@comment line or a single
@ifinfo line. You cannot interpose more than one line between
@node line and the structuring command line; and you may
interpose only an
@comment line or an
Commands which work on a whole buffer require that the ‘Top’ node be
followed by a node with an
@chapter or equivalent-level command.
The menu updating commands will not create a main or master menu for a
Texinfo file that has only
@chapter-level nodes! The menu
updating commands only create menus within nodes for lower level
nodes. To create a menu of chapters, you must provide a ‘Top’
The menu updating commands remove menu entries that refer to other Info files since they do not refer to nodes within the current buffer. This is a deficiency. Rather than use menu entries, you can use cross references to refer to other Info files. None of the updating commands affect cross references.
Texinfo mode has five updating commands that are used most often: two
are for updating the node pointers or menu of a single node (or a
region); two are for updating every node pointer and menu in a file;
and one, the
texinfo-master-menu command, is for creating a
master menu for a complete file, and optionally, for updating every
node and menu in the whole Texinfo file.
texinfo-master-menu command is the primary command:
Create or update a master menu that includes all the other menus (incorporating the descriptions from pre-existing menus, if any).
With an argument (prefix argument, C-u, if interactive), first create or update all the nodes and all the regular menus in the buffer before constructing the master menu. (See The Top Node and Master Menu, for more about a master menu.)
texinfo-master-menu to work, the Texinfo file must have a
‘Top’ node and at least one subsequent node.
After extensively editing a Texinfo file, you can type the following:
C-u M-x texinfo-master-menu
C-u C-c C-u m
This updates all the nodes and menus completely and all at once.
The other major updating commands do smaller jobs and are designed for the person who updates nodes and menus as he or she writes a Texinfo file.
The commands are:
Insert the ‘Next’, ‘Previous’, and ‘Up’ pointers for the node that point is
within (i.e., for the
@node line preceding point). If the
@node line has pre-existing ‘Next’, ‘Previous’, or ‘Up’
pointers in it, the old pointers are removed and new ones inserted.
With an argument (prefix argument, C-u, if interactive), this command
@node lines in the region (which is the text
between point and mark).
Create or update the menu in the node that point is within. With an argument (C-u as prefix argument, if interactive), the command makes or updates menus for the nodes which are either within or a part of the region.
texinfo-make-menu updates an existing menu, the
descriptions from that menu are incorporated into the new menu. This
is done by copying descriptions from the existing menu to the entries
in the new menu that have the same node names. If the node names are
different, the descriptions are not copied to the new menu.
Insert or update the ‘Next’, ‘Previous’, and ‘Up’ pointers for every node in the buffer.
Create or update all the menus in the buffer. With an argument (C-u as prefix argument, if interactive), first insert or update all the node pointers before working on the menus.
If a master menu exists, the
updates it; but the command does not create a new master menu if none
already exists. (Use the
texinfo-master-menu command for
When working on a document that does not merit a master menu, you can type the following:
C-u C-c C-u C-a
C-u M-x texinfo-all-menus-update
This updates all the nodes and menus.
texinfo-column-for-description variable specifies the
column to which menu descriptions are indented. By default, the value
is 32 although it can be useful to reduce it to as low as 24. You
can set the variable via customization (see Customization in The GNU Emacs Manual) or with the M-x set-variable
command (see Examining and Setting Variables in The GNU Emacs Manual).
texinfo-indent-menu-description command may be used to
indent existing menu descriptions to a specified column. Finally, if
you wish, you can use the
texinfo-insert-node-lines command to
@node lines into a file. (See Other Updating Commands, for more information.)