[tex-live] Ignored italic correction with lua(la)tex format

Khaled Hosny khaledhosny at eglug.org
Thu Oct 6 23:49:56 CEST 2011


On Thu, Oct 06, 2011 at 11:31:38PM +0200, Philipp Stephani wrote:
> 2011/10/6 Khaled Hosny <khaledhosny at eglug.org>:
> > Hi all,
> >
> > After a long night of debugging and hair pulling, I finally found why
> > italic correction for OpenType math fonts is ignored in luatex and
> > lualatex formats but not in context.
> >
> > For some reason not yet clear to me, the setting of catcode to 11 in
> > luatex-unicode-letters.tex causes luatex to not apply italic correction
> > (might be related to the fact that luatex applies IC selectively).
> >
> > This minimal example shows the issues:
> >
> > \input luaotfload.sty
> > \font\xits={file:xits-math.otf} at 10pt
> > \textfont0=\xits
> > $$\Umathchar"7"0"1D443\Umathchar"4"0`($$
> > \bye
> >
> > after commenting the \catcode part in line 18 of
> > luatex-unicode-letters.tex and rebuilding the format, italic correction
> > is applied.
> >
> > I'm not sure what is the proper fix here, though.
> 
> LuaTeX explicitly removes italic correction after letters:
> 
>             if (is_new_mathfont(cur_f) && get_char_cat_code(cur_c) == 11) {
>                 *delta = 0;     /* no italic correction in mid-word of
> text font */
> 	    }
> 
> This seems like a bug to me.

This is on purpose, following to MS implementation/Cambria Math. In
either case it makes no sense IMO to give non-letter characters a letter
catcode.

Regards,
 Khaled

-- 
 Khaled Hosny
 Egyptian
 Arab


More information about the tex-live mailing list