[luatex] information about ligatures
Paul Isambert
zappathustra at free.fr
Sun Jan 5 16:40:44 CET 2014
Stephan Hennig <mailing_list at arcor.de> a écrit:
> Am 31.12.2013 09:37, schrieb Paul Isambert:
> > Stephan Hennig <mailing_list at arcor.de> a écrit:
> >
> > Ligatures are char nodes (id 37) with special subtype 2, and they have
> > a “components” field which is a nodelist containing the ligature’s
> > components.
>
> I have already read about subtype 2 and the components field, but have
> never seen a glyph node of that subtype in pre_linebreak_filter.
> Instead, I can see glyph nodes of subtype 256 corresponding to standard
> Unicode ligatures, e.g., 0xfb02 (fl). That is, bit 8 is set in subtype,
> which I can't find any documentation about. For that reason, I have
> never checked the 'components' field, but it is indeed there. Thanks!
[...]
> In fact, all top-level glyph nodes seem to be of subtype 256 in
> pre_linebreak_filter. What does that mean? (You can find the full node
> list corresponding to TeX input 'flavour specific office trick' at the
> end of this mail. With a proper font, the ck ligature is also present
> there.)
>
> Can somebody please provide TeX input that results in a glyph node with
> bit 1 of subtype set?
My two cents is that you’re using luaotfload and that luaotfload sets
“subtype” to 256 for some reason; you’ll see ligatures with proper
subtype 2 if you let TeX do its job with fonts (so use TFM, obviously).
E.g. this in plain TeX:
\setbox0=\hbox{fi}
\directlua{%
texio.write_nl("This ligature has subtype " .. tex.box[0].head.subtype)
}
\bye
It should print “This ligature has subtype 2”.
Why luaotfload sets “subtype” to 256 – if that is indeed the case –, I
really don’t know.
Best,
Paul
More information about the luatex
mailing list