In my document, if an index is the title of a whole chapter, the index is bold. Otherwise, the index is just normal. If the index is from the appendix of my document, it will be italic.

An example would be the following:

Newton Mechanics: 7, 3, 200, 321
Quantum Mechanics: 12, 18, 400, 322

Is it possible that the page number after the index are sorted bold, ascending, and then italic so that it looks like the desired output?

MWE of the document:


\makeindex[title=Stichwortverzeichnis, columns=1]
    heading_prefix "{\\bfseries\\hfil "
    heading_suffix "\\hfil}\\nopagebreak\n"
    headings_flag 1
    symhead_positive ""
    numhead_positive ""
    delim_0 "\\dotfill"
    delim_1 "\\dotfill"
    delim_2 "\\dotfill"


\section{Newton Mechanics\index{Newton Mechanics|textbf}}    
Blablabla\index{Newton Mechanics}


Newton\index{Newton Mechanics|textit}




Is there a way of doing this with imakeidx or xindy and alikes?

  • 2
    The sorting capabilities of makeindex are limited, perhaps it is possible with xindy, but from the LaTeX aspect this is not related to imakeidx or makeidx packages – user31729 Apr 15 '17 at 12:28
  • @ChristianHupfer What tags do you recommend then? I haven't quite found a more suiting one than sorting... – Narusan Apr 15 '17 at 13:11
  • I don't recommend other tags. I just noted that the makeindex processor has limited sorting skills, which will come to its end when seeing something like \bfseries or \textbf{} – user31729 Apr 15 '17 at 13:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.