Next: , Up: Index Support

5.1 Creating Index Entries

In order to index the current selection or the word at the cursor press C-c / (reftex-index-selection-or-word). This causes the selection or word ‘word’ to be replaced with ‘\index{word}word’. The macro which is used (\index by default) can be configured with the variable reftex-index-default-macro. When the command is called with a prefix argument (C-u C-c /), you get a chance to edit the generated index entry. Use this to change the case of the word or to make the entry a subentry, for example by entering ‘main!sub!word’. When called with two raw C-u prefixes (C-u C-u C-c /), you will be asked for the index macro as well. When there is nothing selected and no word at point, this command will just call reftex-index, described below.

In order to create a general index entry, press C-c < (reftex-index). RefTeX will prompt for one of the available index macros and for its arguments. Completion will be available for the index entry and, if applicable, the index tag. The index tag is a string identifying one of multiple indices. With the multind and index packages, this tag is the first argument to the redefined \index macro.