[XeTeX] Localized XeLaTeX / greek XeLaTeX

Ulrike Fischer news3 at nililand.de
Sat Oct 16 15:18:20 CEST 2010

Am Sat, 16 Oct 2010 13:52:40 +0200 schrieb Axel Freyn:

>>> internally by the typesetting system, such as in "\vskip 1 cm",
>>> then it would be much more elegant if the change of the keyboard
>>> could be avoided. For this useage, a nice solution would be to
>>> replace "cm" with e.g. "εκ" (small greek letter epsilon + small
>>> greek letter kappa; which are the first letters for the greek
>>> word "ekatosto" for centimeter). 
>> That's not possible without changing the engine, but like above you
>> can define commands \newcommand\mycm{cm} and use \vskip 1\mycm
> Well, I'm not really programming in xelatex -- but wouldn't it be
> possible analogous to LaTeX be making ε an active character, which
> verifies whether the next character is κ, an then is replaced by "cm" ?

Yes, as you can use a command \mycm you naturally use a command
consisting of an active char. And active chars acting like this are
possible: inputenc with option utf8 is using it.

> OK, of course the disadvantage is that one has to be very careful
> whether this destroys other occurences of ε.

That's the problem. Assuming one do something like this with "c" to
replace "cm" with centimeter, how would you write "pacman"? You
would need a system like the one used by babel to activate and
deactivate the chars - and will still not be able to avoid every
side effect.

Ulrike Fischer 

More information about the XeTeX mailing list