Use Case
Functions
Remove every element whose body is within radius of point. Reuses the same hitTest used by selection, with the eraser disk radius substituted for the pick tolerance — which means stroke width is already accounted for. Returns the original list instance when nothing was hit so callers can skip useless state churn.
Attach connector bindings to an arrow: each endpoint binds to the topmost non-arrow/line shape it sits inside, or to null if it sits in empty space. When this call is what FIRST makes the arrow connect both endpoints, it also seeds a default perpendicular bend so the connector reads as a curve rather than overlapping with the straight center-to-center line.
Update every arrow's endpoints so they terminate on the bound shape's boundary along the line toward the other endpoint (or its bound center). Idempotent — safe to call after any element mutation. Detaches bindings whose target no longer exists.
Recompute new bounds from a resize-handle drag and apply them. Single- element only; multi-selection callers should iterate or refuse.
Set font family key on every selected Element.Text.
Set font size on every selected Element.Text.
Set the stroke pattern on every selected element (shape OR freehand path).
Set text alignment on every selected Element.Text.
Renderer-driven height sync — the canvas measures a text block, sees the rendered height differs from Element.Text.measuredHeight and dispatches io.ak1.drawbox.domain.model.Intent.SyncTextMeasuredHeight to bring the model in line. Bypasses history so this fixed-point convergence doesn't consume undo slots.
Replace the text field of a single Element.Text. Snapshots history.