Class: AnchorLayout

AnchorLayout

AnchorLayout is used in conjunction with AnchorLayoutOptions.

new PUXI.AnchorLayout ()

Example
```
parent.useLayout(new PUXI.AnchorLayout());
```

Methods

calculateAnchor (anchor, limit, limitSubtract)

Calculates the actual value of the anchor, given the parent's dimension.

Name Type Description
anchor number

anchor as given in layout options

limit number

parent's dimension

limitSubtract boolean

true of right/bottom anchors, false for left/top

calculateReach (startAnchor, endAnchor, dimen)

Calculates the "reach" of a child widget, which is the minimum dimension of the parent required to fully fit the child.

Name Type Description
startAnchor number

left or top anchor as given in layout options

endAnchor number

right or bottom anchor as given in layout options

dimen number

measured dimension of the widget (width or height)