@mocanvas/mocanvas · class
declare class DrawShapeUtil extends ShapeUtil<DrawShape, DrawShapeUtilDisplayValues>This one ships without a description. The signature above is read from the package, and the guides cover the area it belongs to.
Methods · 9
canResize(_shape: DrawShape): booleancomponent(_shape: DrawShape): ReactNodegetDefaultProps(): DrawShapePropsgetEngineGeometry(shape: DrawShape): EngineGeometryFreehand smoothing runs in the engine: the raw segment points go across and
the outline is built there. w/h are the extents of the *unsmoothed*
points — the smoothed outline can only sit inside them, and this util sets
neither OVERLAY nor LABEL, so those words feed a fallback the engine
never reaches once the geometry command has run.
getGeometry(shape: DrawShape): Geometry2dgetIndicatorPath(shape: DrawShape): Path2DgetRenderStyle(shape: DrawShape): StyleWordshideResizeHandles(_shape: DrawShape): booleanonResize(shape: DrawShape, info: ResizeInfo<DrawShape>): Partial<DrawShape>Properties · 5
static migrations: _mocanvas_editor.PropsMigrationsstatic options: DrawShapeOptionsreadonly options: DrawShapeOptionsstatic props: _mocanvas_editor.RecordProps<DrawShape>static type: "draw"mocanvas is built by Symbio. Free for non-commercial, non-profit and development use; commercial use needs an agreement. Not affiliated with or endorsed by tldraw.