Set Size to the Positional Extent of a Previous Gadget
- Last UpdatedJan 28, 2025
- 1 minute read
A new gadget's size component can be specified as the distance from its placement position co-ordinate to the Positional Extent of another gadget (MINimum, CENtre or MAXimum), for example:
frame .fr2 |Frame 2| at ymax.fr1 Width To min.fr1 Height To cen
frame .fr3 |Frame 3| at ymax.fr2 Width To max.fr1 Height To max Form
The width of fr2 extends from its implied X-position (XMIN of last placed gadget) to the minimum X-position of gadget fr1. Its height extends from its specified Y-position (YMAX of fr1) to the center position of the most recently defined gadget.
Notes
-
Sizing to a positional extent makes accurate aligning of gadgets much easier and is essential for laying complex resizable forms
-
It always defines the full gadget size component, regardless of gadget type or presence of tag text.
-
For the full syntax, refer to Gadget Size Syntax.