[luatex] Getting a glue node subtype on lua side
Paul Isambert
zappathustra at free.fr
Mon May 23 15:09:18 CEST 2011
Le 23/05/2011 11:59, Christophe Jorssen a écrit :
> 2011/5/23 Paul Isambert<zappathustra at free.fr>:
>> There is no such function, but you can do it yourself:
>>
> [snip]
>> Of course you have to check development regularly to make sure glue subtypes
>> don't change (for instance, I think there might be a
>> glue-from-space-character subtype someday).
>>
> Ok. Thank you.
>
> Sorry to ask, but is there a reason why it is not implemented? From my
> (newbie) point of vue, there is no difference between hard coded node
> types (for which node.id is provided) and hard coded node subtypes?
> So, what about a node.subtypeid?
I think the reason is that there are many different node ids and whatsit
subtypes, and that the numerical value might change before LuaTeX is
stable. So a function that always return the right number is essential.
On the other hand, nodes, except whatsits, don't have many subtypes, so
numerical values are ok (not that I'm against the idea of your
node.subtypeid function, mind you). Glue nodes appear to be crowded
after all, but Taco's just said he would add a function if things
changed (and they will, I suppose, because the glue-from-space-character
I mentioned is a long-awaited subtype).
Best,
Paul
More information about the luatex
mailing list