Next: , Previous: Equation reference hyperlinks, Up: Implicit hyperlinks


5.3.8 Index hyperlinks: idx

All indexing commands (\idx, \idxname, \idxmarked, \idxsubmarked and their silent equivalents, see Indexing commands) form the `idx' destgroup. The `idx' linkgroup consists of the macros which are used to typeset the index when you say \readindexfile{index-letter} (see Typesetting an index).

To create the links in index entries, Eplain uses MakeIndex's “encapsulation” feature. When you use an indexing macro to mark an index term, Eplain writes out a line to the .idx file of the following general form:

     \indexentry{entry|pagemarkup}{pageno}

where entry is the index entry (converted into the internal format that MakeIndex understands), cs is the markup command you specified with the pagemarkup=cs optional argument to the indexing commands (see Modifying index entries), and pageno is the page number on which the term appeared. When processing the .idx file, MakeIndex makes the page number an argument to the page markup command (“encapsulates” the page number), so the page number in the .ind file appears as \cs{pageno}. Eplain internally replaces the cs command name with its own command, which, in addition to calling the original \cs encapsulator, turns the page number into a link.

Eplain provides two approaches to linking page numbers in the index to locations of index terms in the text.