Class: FastLayoutOptions

FastLayoutOptions

PUXI.FastLayoutOptions is an extension to PUXI.LayoutOptions that also defines the x & y coordinates. It is accepted by the stage and PUXI.FastLayout.

If x or y is between -1 and 1, then that dimension will be interpreted as a percentage of the parent's width or height.

new FastLayoutOptions ()

Extends

Members

anchor PIXI.Point

The anchor is a normalized point telling where the (x,y) position of the widget lies inside of it. By default, it is (0, 0), which means that the top-left corner of the widget will be at (x,y); however, setting it to (.5,.5) will make the center of the widget be at (x,y) in the parent's reference frame.

Default Value:
  • PUXI.FastLayoutOptions.DEFAULT_ANCHOR

height number inherited overrides

Preferred height of the widget in pixels. If its value is between -1 and 1, it is interpreted as a percentage of the parent's height.

Default Value:
  • {PUXI.LayoutOptions.WRAP_CONTENT}

marginBottom number inherited overrides

The bottom margin in pixels of the widget.

Default Value:
  • 0

marginLeft number inherited overrides

The left margin in pixels of the widget.

Default Value:
  • 0

marginRight number inherited overrides

The right margin in pixels of the widget.

Default Value:
  • 0

marginTop number inherited overrides

This top margin in pixels of the widget.

Default Value:
  • 0

width number inherited overrides

Preferred width of the widget in pixels. If its value is between -1 and 1, it is interpreted as a percentage of the parent's width.

Default Value:
  • {PUXI.LayoutOptions.WRAP_CONTENT}

x number

X-coordinate of the widget in its parent's reference frame. If it is absolutely less than 1, then it will be interpreted as a percent of the parent's width.

Default Value:
  • 0

y number

Y-coordinate of the widget in its parent's reference frame. If it is absolutely less than 1, then it will be interpreted as a percent of the parent's height.

Default Value:
  • 0