[XeTeX] epsdice package.
Philip TAYLOR (Webmaster, Ret'd)
P.Taylor at Rhul.Ac.Uk
Mon Jul 18 12:45:08 CEST 2011
Peter Dyballa wrote:
> Right! Make character \n active and \define it as character \n from font \Cher.
Yes, that is the right approach, but implementing it successfully
requires use of \uccode & \uppercase, or \lccode and \lowercase,
and the \uppercase/lowercase primitives are, in general, very
poorly understood. Perhaps easier is to make use of the fact
that Michael has \XeTeXinterchartoks available to him :
\documentclass {minimal}
\usepackage {fontspec}
\setmainfont {Comic Sans MS}
\newfontfamily \Latinfont {Comic Sans MS}
\newfontfamily \Cherokeefont {Code2000}
\newcount \n
\def \TreatCherokeeCharactersSpecially
{\n = "13A0
\loop
\XeTeXcharclass \n = 4 \relax
\ifnum\n < "13FF
\advance \n by 1 \relax
\repeat
\XeTeXinterchartokenstate = 1
\XeTeXinterchartoks 0 4 = {\Cherokeefont}
\XeTeXinterchartoks 4 0 = {\Latinfont}
\XeTeXinterchartoks 255 4 = {\Cherokeefont}
\XeTeXinterchartoks 4 255 = {\Latinfont}
}
\begin {document}
The Cherokee alphabet is a Syllabary.
ᏌᏊ: Sah-Gwoo (the "g" here is a bit hard, more like a "k", but not that hard)
ᏍᎪᎯ: Skoh-Hee (the "k" here is a bit soft, more like a "g", but not that soft)
\TreatCherokeeCharactersSpecially
The Cherokee alphabet is a Syllabary.
ᏌᏊ: Sah-Gwoo (the "g" here is a bit hard, more like a "k", but not that hard)
ᏍᎪᎯ: Skoh-Hee (the "k" here is a bit soft, more like a "g", but not that soft)
\end {document}
** Phil.
More information about the XeTeX
mailing list