[XeTeX] Runaway argument issues

Herbert Schulz herbs at wideopenwest.com
Wed Oct 12 00:29:33 CEST 2011


On Oct 11, 2011, at 4:54 PM, Chris Travers wrote:

> Here is a minimal sample to reproduce the problem:
> 
> \documentclass{article}
> \usepackage{longtable}
> \begin{document}
> 
> \begin{longtable}{ll}
> 
>   \textbf{Número}
>  & \textbf{Descripción}
> \endhead
> \end{longtable}
> 
> \end{document}
> 
> 
> When I run this with xelatex, I get:
> 
> Runaway argument?
> {Descripci������ \endhead \end {longtable} \par \end {document} \par
> ! File ended while scanning use of \textbf .
> 
> Now, if I replace the ó with \'o, that part works fine (but then why
> would I be using xelatex?) but the Número ends up displaying as N.
> 
> As far as I can tell the problem is with handling of multibyte
> characters.  Removing the \textbf{} from around the problem phrase
> ends up having it rendered as Descripciendhead, suggesting several
> more bytes are being assumed to be part of the character than actually
> are.
> 
> Best Wishes,
> Chris Travers


Howdy,

1)Did you save the file as UTF-8 Unicode?

2)What you have will use Computer Modern which doesn't have the accented characters as single glyphs so it doesn't know how to handle them. To use Latin Modern by default add

\usepackage{fontspec}

in the preamble and, if you want to use a system font (e.g., Linux Libertine) ad the line

\setmainfont{Linux Libertine}

in the preamble after the fontspec load.

Good Luck,

Herb Schulz
(herbs at wideopenwest dot com)






More information about the XeTeX mailing list