A LaTeX makeindex
style with dashes to indicate subitems and subsubitems is desired. The posting Makeidx, Subentries and dashes here looked like the ticket. With the suggested additions, and a couple from elsewhere, here is the modified .ist
preamble "\\begin{theindex}\\thispagestyle{empty}\n"
quote '+'
headings_flag 1
heading_suffix ""
item_1 "\n \\subitem --- "
item_x1 "\n \\subitem --- "
item_2 "\n \\subsubitem --- --- "
item_x2 "\n \\subsubitem --- --- "
delim_0 ": "
delim_1 ": "
delim_2 ": "
delim_r "-"
suffix_2p "\\,f."
suffix_3p "\\,ff."
The following LaTeX MWE was tested with the style file above (the idxlayout package is used to kill the indents and get a multicolumn index)
\documentclass{article}
\usepackage{makeidx}
\usepackage[subindent=0pt,subsubindent=0pt, totoc=true]{idxlayout}
\makeindex
\begin{document}
ParentA\index{ParentA}, SubAA\index{ParentA!SubAA}, SubAB\index{ParentA!SubAB}, SubAC\index{ParentA!SubAC}
ParentB\index{ParentB}, SubBA\index{ParentB!SubBA}, SubsubBAA\index{ParentB!SubBA!SubsubBAA}, SubsubBAB\index{ParentB!SubBA!SubsubBAB}, SubBB\index{ParentB!SubBB}
\printindex
\end{document}
The problem is that, in the output, the first subitem in a list of subitems does not get the preceding dash(es)
even though the second, third, etc. do. The desired index output is
The undesired output only seems to happen when the parent item is itself indexed in the document (and so gets a page number in the index). How may I achieve the desired index format?