# index and item separation

I'm currently creating an index with the book class. I would like to play with the vertical separation between items in the index. Below is what I am redefining:

\renewcommand\@idxitem{\par\hangindent 40\p@}
\renewcommand\subitem{\vspace*{-2\p@}\@idxitem \hspace*{20\p@}}
\renewcommand\subsubitem{\vspace*{-4\p@}\@idxitem \hspace*{30\p@}}


and I control the vertical space with two \vspace* commands. Is this correct? Thanks

-
add comment

## 1 Answer

Your approach will produce variable vertical separation. However, by adding negative vertical space to subitems and subsubitems, their respective separation will actually be smaller than the vertical space between two lines of the same ((sub)sub)item, which may be confusing (besides producing rather cramped text lines). As an alternative, consider adding positive vertical space to items and subitems.

-
but I want them to be closer than two consecutive lines in the main text. I was trying to redefine \baselinestretch just for the index but as a list, it does not seem sensitive to this parameter. –  pluton Sep 9 '10 at 17:11
Have you tried to use a smaller font for the index? (Shameless plug: \usepackage[font=small]{idxlayout}.) –  lockstep Sep 10 '10 at 12:06
thanks, I'll give it a try soon. –  pluton Sep 10 '10 at 14:22
add comment