Home > @jsplumbtoolkit/core > AbstractLayout > magnetize
AbstractLayout.magnetize() method
Run the magnetizer.
Signature:
magnetize(params: {
options?: MagnetizerRunOptions<any>;
origin?: PointXY;
focus?: string;
}, internal: boolean): Record<string, {
original: PointXY;
current: PointXY;
}>;
Parameters
Parameter | Type | Description |
---|---|---|
params | { options?: MagnetizerRunOptions<any>; origin?: PointXY; focus?: string; } | Options for the magnetizer. |
internal | boolean | whether or not the magnetize call was made by the layout itself. |
Returns:
Record<string, { original: PointXY; current: PointXY; }>