Currently, I have Apêndice A Title of the appendix in my Table of Contents (see link below), but I need APÊNDICE A – Title of the appendix (note the capital letters APÊNDICE and the "en dash" before the title.

This change must affect only the ToC. The title on the appendix page itself is fine as it is now.

I guess this is an easy task, but I haven't succeeded.






Bla bla

\chapter{Title of the appendix}
\chapter{Title of another appendix}

  • Are you trying to copy the ABNT style? – user9424 Apr 20 '19 at 0:59
  • @Joseph, I have to adapt a book to the norms of ABNT. I have already tried simply to replace the class book with abntex, but some packages I use didn't work in that class. – Leonardo Castro Apr 20 '19 at 2:30
  • The class is called abntex2, not abntex. You'll have plenty more problems trying to do it all from scratch. Better ask people here or elsewhere why those packages don't work with abntex2 -- have you tried that? By the way, who on earth has to adapt a book (not a thesis) to ABNT rules? Which publisher prints a book only according to ABNT and accepts LaTeX? This may seem picky, but changing your approach might save you lots of time. – user9424 Apr 20 '19 at 2:35
  • Yes, it was abntex2 what I tried. It's a university publisher which really requires ABNT for books too. They usually required the book text as a Microsoft Word file (for they to pass it to InDesign), but they accepted PDF files from LaTeX users as long as the authors adapt their books to the rules themselves. – Leonardo Castro Apr 20 '19 at 3:21
  • Traditionally, this publisher focused on humanities books, but now they are starting publishing natural science books too. Many science authors submitted their books as PDF files and only revealed that they didn't have a DOC file after having the books accepted. – Leonardo Castro Apr 20 '19 at 3:32

Part of your question can be answered by this answer.

For renaming, you'll need to add this:

  • My appendices are defined as chapters (as I have book instead of article). What's the equivalent to \@seccntformat for chapters? – Leonardo Castro Mar 13 '19 at 20:31

I'm answering my own question to complement @Vinccool96's answer.

The answer of @Vinccool96 didn't completely apply to my MWE because its class is book instead of article. However, it helped me find the solution that worked in my case.

Based on the explanation in https://tex.stackexchange.com/a/384048/91816, I added the following code immediately below \begin{appendices}:

\def\@chapter[#1]#2{\ifnum \c@secnumdepth >\m@ne
    {\thechapter\space\textendash\space\ #1}% <-- modification

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.