[texhax] Weirdness with bold, italic and colored text and the fontspec package

Peter Davis pfd at pfdstudio.com
Thu Nov 18 22:19:34 CET 2010


I'm trying to use the fontspec package, and also use xcolor to specify
colored text, which may also be bold or italic.  However, as the example
below demonstates, I get some weirdness with XeTeX v3.1415926-2.2-0.9997.4
(MiKTeX 2.9).  Specifically, it seems like each time a change one of the
attributes (color, bold, italic), the very next glyph is drawn correctly,
but then the following glyphs are drawn roman, regardless of the italic
setting.  Any clues?

Here's the sample:


%%!TEX TS-program = latex

\documentclass{article}


\usepackage{fontspec}

 %\usepackage[usenames]{color}

\usepackage{xcolor}

\definecolor{color13}{cmyk}{0,0.87,0.87,0}


\begin{document}


\fontsize{14}{14}

\fontspec{Minion Pro}


{\textit italic}{\fontspec[Color=color13]{Minion Pro}\textit red italic}
{\fontspec[Color=color13]{Minion Pro}\bfseries{\textit red bold
italic}}{\bfseries{\textit bold italic}}


\end{document}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://tug.org/pipermail/texhax/attachments/20101118/b6a7cb0c/attachment.html>


More information about the texhax mailing list