Skip to main content

SurfaceVertexCloneOptions

Options for a clone operation in a Surface

Extends

Properties

flash?

optional flash: boolean

Defaults to false. If true, briefly flash the new vertex after the clone.


magnetize?

optional magnetize: boolean

When the UI is in constant magnetize mode, the default behaviour - if you do not provide a newPosition - is to magnetize a newly cloned vertex, so that it moves to fit into whitespace. Without this, when the user drags a newly cloned vertex that is overlapping the vertex it was cloned from, the original vertex is magnetized out of the way, and the experience is a bit disconcerting for the user. When the UI is not in constant magnetize mode, the default is to not magnetize. Set this flag explicitly to get the behaviour you desire if the default doesnt suit.

Inherited from

VertexCloneOptions.magnetize


newPosition?

optional newPosition: PointXY

Optional position to use for the new vertex

Inherited from

VertexCloneOptions.newPosition


offsetPosition?

optional offsetPosition: PointXY

Defaults to 50 pixels in X and Y - the offset to use for the new vertex's position. Ignored if you provide newPosition.

Inherited from

VertexCloneOptions.offsetPosition


selectAfterCreate?

optional selectAfterCreate: boolean

If true, the newly cloned vertex will be set as the model's current selection.

Inherited from

VertexCloneOptions.selectAfterCreate