[luatex] vpack filter question

Taco Hoekwater taco at elvenkind.com
Wed Dec 8 21:03:12 CET 2010

On 12/08/10 17:43, Paul Isambert wrote:
> Le 08/12/2010 15:35, Patrick Gundlach a écrit :
>> with the document below I get the hboxes correct, but the vboxes seem
>> a bit strange to me. Can someone explain the dimensions of the vbox?
>> Or are they just not calculated yet, so I can't use
>> node.dimensions(<head's glue specs>, vlist) at that time?
> I suppose node.dimensions produces an hlist, since you can't choose
> between h- or vmode to build the list, and it works perfectly well
> horizontally.

Pretty much: it generates the dimensions of all the stuff in the list
*as if* it was created in horizontal mode.

> doesn't make sense; a list of node isn't vertical or horizontal, it
> simply occurs in a vertical or horizontal container (... unfortunately
> also called a list). But I might be completely wrong.

No, that is accurate. The only difference is that some node objects
only appear in one case (there are no glyphs allowed in vertical
containers, for instance) but node.dimensions does not check that.

> Anyway it'd be nice indeed to have a switch for node.dimensions which
> measure either vertically or horizontally.

Vertical lists are usually short and consist of boxes and glues
for which all dimensions are already known, so it should be pretty
simple to write a lua function for that. The case for horizontal
lists is a lot harder to do in lua because of the need to fetch
font dimensions.


More information about the luatex mailing list