1

The following file works fine when run with the choice of "english" but not "portuguese" under XeLaTeX;

\documentclass{report}

\usepackage{soul}

\usepackage{polyglossia} % \setdefaultlanguage{english} \setdefaultlanguage{portuguese}

\usepackage{xcolor} \usepackage{pdfcomment}

\begin{document}

This should show in yellow: \pdfmarkupcomment[markup=Highlight,color=yellow]{Mittag-Leffler}{Highlight} after running \LaTeX{} three times.

\end{document}

I am aware of the recommendation by Ulrike Fisher here to load the package soul earlier and choose the language later. This solves the problem for LuaLaTeX, but not for XeLaTeX.

Under TL'23, running xelatex filename, one gets:

(/usr/local/texlive/2023/texmf-dist/tex/generic/stringenc/se-ascii-print.def)
! Extra \else.
\portuguese@sh@tmp ...\portuguese@sh@next --\else 
                                                  \expandafter \portuguese@@...
l.15 ...t,color=yellow]{Mittag-Leffler}{Highlight}
                                                   after running \LaTeX{} th...

Are there any ways to run these two packages together under XeLaTeX?

Paulo Ney
  • 2,405

0 Answers0