[XeTeX] Table of contents

José Carlos Santos jcsantos at fc.up.pt
Thu Apr 29 20:01:19 CEST 2010


Hi all:

Please consider this file:

------------------------------- test.tex -------------------------------
\documentclass[10pt,a4paper]{book}
\usepackage[frenchb]{babel}
\usepackage{fontspec}
\usepackage{xunicode}
\usepackage{xltxtra}
\begin{document}
\frontmatter
\tableofcontents
\XeTeXinputencoding "cp1252"
\XeTeXdefaultencoding "cp1252"
\mainmatter\setcounter{secnumdepth}{2}
\chapter{Général de Gaulle}
Il était français.
\end{document}
------------------------------------------------------------------------

As you may guess from its contents, the encoding that I am using is
cp1252. If I compile this file, then, at the table of contents I get
"Général de Gaulle", instead of "Général de Gaulle".

I can eliminate this by commenting the line

\XeTeXdefaultencoding "cp1252"

but I want to have it there in order to be able to have a file for each
chapter and to use the \include command. What should I do?

Best regards,

Jose Carlos Santos


More information about the XeTeX mailing list