Skip to main content
AlignContentOptions
Options for aligning content in the UI.
NameTypeDescription
alignX?CanvasAlignmentXHow to align the content in the X axis - left, right or center
alignY?CanvasAlignmentYHow to align the content in the Y axis - top, bottom or center
animationDuration?numberHow long, in milliseconds, the animation should take to run.
doNotAnimate?booleanIf true, don't animate while centering. Defaults to false, ie. the operation will be animated.
onComplete?(p:PointXY) => anyOptional function to call on operation complete.
padding?numberHow much padding to leave around the content.
zoom?numberZoom to set prior to alignment