1

I would like to add a ``THE END'' to the end of an Index.

Is there a command when creating an Index analogous to the \addtocontents command for the TOC? I am using PDFLATEX.

Consider the MWE

\documentclass[12pt]{book}
\usepackage{imakeidx}
\makeindex
\usepackage{idxlayout}

\begin{document}
\thispagestyle{empty}
Sentence\index{Index Entry1} \newpage
Sentence\index{Index Entry2} \newpage

\idxlayout{columns=2}
\printindex
\end{document}

which produces the Index:

enter image description here

Again, I would like to add ``THE END'', preferably centered, somewhere after the index entries.

Thank you.

1
  • how to be more simple: say simpler instead of more simple?
    – BCLC
    Jul 7, 2021 at 18:57

1 Answer 1

2

You can just put the extra text after \printindex. Below I added a bit of vertical space.

\documentclass[12pt]{book}
\usepackage{imakeidx}
\makeindex
\usepackage{idxlayout}

\begin{document}
\thispagestyle{empty}
Sentence\index{Index Entry1} \newpage
Sentence\index{Index Entry2} \newpage

\idxlayout{columns=2}
\printindex

\vspace{1cm}\centering\large THE END
\end{document}

enter image description here

3
  • Thank you. That works nicely. However, would you know if this can be done using some type of index command, which might offer the possibility of adding (positioned) comments/statements within the Index itself? something analogous to the addtocontents command that Table of Contents has? Thank you again for your useful answer.
    – DDS
    Jul 7, 2021 at 19:27
  • 1
    @mlchristians what kind of comment/statement do you want to include? There is the possibility of creating categories that are printed within the index, see for example tex.stackexchange.com/questions/593382/…. For random comments you might be able to add an index entry without page number, but that would need some tricks, e.g., tex.stackexchange.com/questions/52142/…. But if you want you can open a new question to make your new use case clear.
    – Marijn
    Jul 7, 2021 at 19:44
  • Thank you for your helpful comment.
    – DDS
    Jul 7, 2021 at 19:59

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .