Welcome to Al-gul

The Middle East and More

LaTex Indexing Tips–Fix Ascending Sub-Entries

leave a comment »

1. If you are creating an index in LaTex where there will sub-entries, keep in mind that the order of the sub-entries must be descending so that they display properly.  So the syntax is 

\index{Civil War!Battles!Gettysburg}
and not the other way around.
2. To create the index you must:
a. Run LaTex (or XeLaTex, or PDFLaTex or whatever engine you prefer)
b. Run makeindex (from the command line if your LaTex front-end doesn’t support it)
c. Run LaTex again. 
While these two points are pretty basic, I did not find them displayed clearly while rummaging around in the documentation.
Finally, if like me you indexed a long document putting the sub-entries in the wrong order, I can post a Python script that will fix things. Thanks to Tizen on Fiverr.com!

Written by mokane

March 25, 2013 at 7:30 am

Posted in Uncategorized

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: