[OS X TeX] Unicode en-dash problems on XeLaTeX

Alan Munn amunn at gmx.com
Sun Feb 14 21:44:45 CET 2016


Please don’t cross post on mailing lists and Stackexchange.

http://tex.stackexchange.com/q/292904/2693

Since you’ve already gotten answers there, it’s wasting people’s time who just read one or the other.

Alan



> On Feb 14, 2016, at 2:24 PM, Chris Lott <chris at chrislott.org> wrote:
> 
> Given the simple document below, why does the en-dash (and only the
> en-dash) unicode character cause this error:
> 
> ./dash-testing.te.tex:13: Undefined control sequence.
> l.13 Hello\UTF
>              {2013}world!
> 
> I've tested with various fonts, all of which have this common
> character in the proper Unicode "position" in the font (verified with
> InDesign Glyph Viewer, etc).
> 
> The filetype is UTF-8:
> $ file -I dash-testing.te.tex
> dash-testing.te.tex: text/x-tex; charset=utf-8
> 
> Here is what the file looks like if I "Continue" past the error:
> https://db.tt/EeI7pIMP
> 
> Why does just the en-dash hate me?
> 
> ***
> \documentclass{article}
> \usepackage{fontspec}
> \setmainfont{Gentium Plus}
> 
> \begin{document}
> 
> Hello---world!
> 
> Hello—world!
> 
> Hello--world!
> 
> Hello–world!
> 
> Demonstrating that “other” unicode characters work:
> 
>> 
> Baby, it's cold° outside.
> 
> \end{document}
> ***
> 
> c
> --
> Chris Lott <chris at chrislott.org>
> 
> ----------- Please Consult the Following Before Posting -----------
> TeX FAQ: http://www.tex.ac.uk/faq
> List Reminders and Etiquette: https://www.esm.psu.edu/~gray/tex/
> List Archives: http://dir.gmane.org/gmane.comp.tex.macosx
>                https://email.esm.psu.edu/pipermail/macosx-tex/
> TeX on Mac OS X Website: http://mactex-wiki.tug.org/
> List Info: https://email.esm.psu.edu/mailman/listinfo/macosx-tex

-- 
Alan Munn
amunn at gmx.com





----------- Please Consult the Following Before Posting -----------
TeX FAQ: http://www.tex.ac.uk/faq
List Reminders and Etiquette: https://www.esm.psu.edu/~gray/tex/
List Archives: http://dir.gmane.org/gmane.comp.tex.macosx
                https://email.esm.psu.edu/pipermail/macosx-tex/
TeX on Mac OS X Website: http://mactex-wiki.tug.org/
List Info: https://email.esm.psu.edu/mailman/listinfo/macosx-tex



More information about the macostex-archives mailing list