[XeTeX] Problem: Beamer+xelatex+\XeTeXdefaultencoding

Ross Moore ross.moore at mq.edu.au
Tue Jun 22 07:58:08 CEST 2010


Hi again Heiko,

On 22/06/2010, at 2:17 PM, Heiko Oberdiek wrote:

>> The problem is perhaps really within LaTeX's  
>> \IfFileExists  command.
>> 
>> It doesn't use TeX's  \immediate  qualifier
>> when calling  \openin  and  \closein for the preliminary
>> check to see whether the file exists or not.
>> The need for this primitive is discussed in the TeXbook ,
>> and surely the preliminary check is precisely a place
>> where it should be used.
> 
> You mean \openout/\write/\closeout?
> \openin, \read, \closein are always "\immediate".

Yes, OK. It doesn't really make any sense otherwise.
So I've had another look, at it seems to be a line-end,
or rather, a macro-name end, problem.

LaTeX's coding for  \IfFileExists  has the following:

\def\IfFileExists#1#2#3{%
  \openin\@inputcheck#1 %
  \ifeof\@inputcheck
     #3\relax
  ...

The problem goes away upon changing that 2nd line 
to
   \openin\@inputcheck#1%
or  
   \openin\@inputcheck{#1}%

So somehow that trailing space has a greater effect
than intended. That's likely to be a subtle bug in XeTeX,
since it hasn't been reported before with other engines.

The coding example in my previous message fixed the problem,
but not for the reason that I had first thought.

> 
> Yours sincerely
>  Heiko Oberdiek
> 
> PS: my e-mail address has changed, the old one will stop working
> in near future.

OK; noted.

Mine has changed too, after many years and mountains
of SPAM being sent to the previous one.


Cheers,

	Ross

------------------------------------------------------------------------
Ross Moore                                       ross.moore at mq.edu.au 
Mathematics Department                           office: E7A-419      
Macquarie University                             tel: +61 (0)2 9850 8955
Sydney, Australia  2109                          fax: +61 (0)2 9850 8114
------------------------------------------------------------------------





More information about the XeTeX mailing list