斜體索引條目

斜體索引條目

我正在使用makeidx.

下面這個不好嗎?這對我不起作用。

\index{Brazil!\textit{subentry text}}

沒有斜體 ( \index{Brazil!subentry text}) 的效果相同。

答案1

子條目的排序順序可能是錯誤的,因為\textit它包含在排序字串中。 -符號@可用於指定排序鍵,而無需標記命令:

\documentclass{article}
\usepackage{makeidx}
\makeindex

\begin{document}
\null
\index{Brazil!aaa}
\index{Brazil!zzz}
\index{Brazil!\textit{wrong entry}}
\index{Brazil!subentry text@\textit{subentry text}}
\printindex
\end{document}

命令:

pdflatex test
makeindex test
pdflatex test

結果

相關內容