Skip to main content

AlignContentOptions

Options for aligning content in the UI.

Properties​

alignX?​

optional alignX: CanvasAlignmentX

How to align the content in the X axis - left, right or center


alignY?​

optional alignY: CanvasAlignmentY

How to align the content in the Y axis - top, bottom or center


animationDuration?​

optional animationDuration: number

How long, in milliseconds, the animation should take to run.


doNotAnimate?​

optional doNotAnimate: boolean

If true, don't animate while centering. Defaults to false, ie. the operation will be animated.


onComplete()?​

optional onComplete: (p) => any

Optional function to call on operation complete.

Parameters​

p​

PointXY

Returns​

any


padding?​

optional padding: number

How much padding to leave around the content.


zoom?​

optional zoom: number

Zoom to set prior to alignment