[XeTeX] XeTeXinterchartoks and spacefactor

Takayuki YATO (ZR) zrbabbler at yahoo.co.jp
Sat Nov 20 13:06:01 CET 2010


Hi,

The story seems that when XeTeX inserts tokens due to
\XeTeXinterchartoks it has already read the character at the
right side of the insertion point for update of the space
factor value.

\newXeTeXintercharclass \cclA
\newXeTeXintercharclass \cclB
\newXeTeXintercharclass \cclC
\XeTeXcharclass `\A \cclA \sfcode `\A 1234
\XeTeXcharclass `\B \cclB \sfcode `\B 2010
\XeTeXcharclass `\C \cclC \sfcode `\C 3000
\XeTeXinterchartoks \cclA \cclB = {\the\spacefactor}
\XeTeXinterchartoks \cclB \cclC = {\the\spacefactor}
\XeTeXinterchartokenstate = 1
ABC   % Prints "A2010B3000C"
\bye

Thus in your example:

> A.\the\spacefactor % 3000; should be 1000?

update for <.> appears to occur twice:

A(999) --> .(1000) --> .(3000)


--- Dohyun Kim <nomosnomos at gmail.com> wrote:

> Hi,
> 
> =====
> \newXeTeXintercharclass \mycharclassA
> \newXeTeXintercharclass \mycharclassP
> \XeTeXcharclass `\A \mycharclassA
> \XeTeXcharclass `\. \mycharclassP
> \XeTeXinterchartoks \mycharclassA \mycharclassP = {\relax}
> 
> \XeTeXinterchartokenstate = 0
> A\relax.\the\spacefactor % 1000; ok.
> 
> \XeTeXinterchartokenstate = 1
> A.\the\spacefactor % 3000; should be 1000?
> 
> \bye
> =====
> 
> I expected the same spacefactor between the first line and the
> second.
> Actually it is not, however.  Is this a bug of XeTeX?
> 
> -- 
> Dohyun Kim
> College of Law, Dongguk University
> Seoul, Republic of Korea
> 
> 
> --------------------------------------------------
> Subscriptions, Archive, and List information, etc.:
>   http://tug.org/mailman/listinfo/xetex
> 


Tak Yato (Takayuki YATO; aka. ZR)

--------------------------------------
Yahoo! Toolbar  -  For your Internet Safety
http://pr.mail.yahoo.co.jp/toolbar2/


More information about the XeTeX mailing list