[XeTeX] Embarrassing fontspec

Will Robertson will at guerilla.net.au
Wed Jan 4 06:57:09 CET 2006


Hello,

In trying to complete fontspec 1.9 before the new year properly  
begins, I've come across a very strange problem that has me totally  
stumped.

The fontspec documentation contains lots and lots of examples, and I  
noticed that after a certain number of them, the default roman text  
went all funny. In order to determine that it was indeed fontspec's  
fault and no other, I assembled a test file that contained only the  
examples from fontspec.dtx, typeset directly, with some counting text  
in-between. Look what happens:

-------------- next part --------------
A non-text attachment was scrubbed...
Name: texshop_image.png
Type: image/png
Size: 25813 bytes
Desc: not available
Url : http://tug.org/pipermail/xetex/attachments/20060104/9a6a37e2/texshop_image-0001.png
-------------- next part --------------

The "test words 50" text seems to take up no space (the \fbox is just  
a single line) and the characters are truncated after the first four,  
and are obviously in the wrong spots.

A similar test with plain XeTeX commands yielded fine results, so  
somewhere in fontspec, I've made a terrible error. But what on earth  
could it be? Am I using up some of XeTeX's mojo, and it eventually  
forgets how to place characters on the page properly?

Looking at tracing an hbox when this craziness is going on  
demonstrates what's going on more clearly: (the \hbox is -4055pt  
wide?!?)

 > \box0=
\hbox(7.21+2.79)x-4055.02191
.\U/Hoefler Text (0)/m/n/10 test
.\glue *
.\U/Hoefler Text (0)/m/n/10 words

But when I try and replicate the problem without fontspec (using  
plain \font primitives), I get no problems:

 > \box0=
\hbox(9.87305+3.32813)x55.16602
.\U/Palatino (0)/m/n/12 test
.\glue 3.0 plus 2.0 minus 1.0
.\U/Palatino (0)/m/n/12 words

(Ignore the font and size differences; they are irrelevant.)

So I know this is pretty much impossible for anyone to debug without  
access to my stuff (and especially because it seems that the problem  
is a combination of both fontspec *and* LaTeX's obfuscated NFSS), but  
I'm throwing it out here because I have no idea what to try next.

Maybe someone's seen the error before, but I doubt it. I've attached  
(a highly pre-release version of) fontspec 1.9 and the example file  
that breaks if it could be confirmed that the problem isn't corrupted  
fonts at my end (you'll need xkeyval 2.5 as well, also attached).  
Otherwise, any ideas?

Any help would be greatly appreciated,

Will

-------------- next part --------------
A non-text attachment was scrubbed...
Name: zf-too-many.tex
Type: application/octet-stream
Size: 14710 bytes
Desc: not available
Url : http://tug.org/pipermail/xetex/attachments/20060104/9a6a37e2/zf-too-many-0001.obj
-------------- next part --------------

-------------- next part --------------
Skipped content of type multipart/appledouble-------------- next part --------------
A non-text attachment was scrubbed...
Name: keyval.tex
Type: application/octet-stream
Size: 2517 bytes
Desc: not available
Url : http://tug.org/pipermail/xetex/attachments/20060104/9a6a37e2/keyval-0001.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: xkeyval.sty
Type: application/octet-stream
Size: 4934 bytes
Desc: not available
Url : http://tug.org/pipermail/xetex/attachments/20060104/9a6a37e2/xkeyval-0002.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: xkeyval.tex
Type: application/octet-stream
Size: 24865 bytes
Desc: not available
Url : http://tug.org/pipermail/xetex/attachments/20060104/9a6a37e2/xkeyval-0003.obj


More information about the XeTeX mailing list