pack-pref-dim ( pack sizes -- dim )
Factor handbook » UI framework » Building user interfaces » Gadget hierarchy and layouts » Pack layouts

Prev:<shelf> ( -- pack )
Next:pack-layout ( pack sizes -- )


Vocabulary
ui.gadgets.packs.private

Inputs
packa pack
sizesa sequence of pairs of integers


Outputs
dima pair of integers


Word description
Computes the preferred size of a pack, with each gadget receiving its size from the corresponding index of the sizes sequence.

Notes
This word is useful if you are writing your own layout gadget which inherits from pack. This allows you to reuse layout logic while computing gadget sizes using a custom procedure.

Definition