setMousePositionWorld method

void setMousePositionWorld(
  1. GraphPosition? position
)

Updates the mouse position in graph coordinates.

This is typically called internally by the editor widget during mouse hover. Pass null when the mouse exits the canvas.

Parameters:

  • position: The mouse position in graph coordinates, or null if outside canvas

Implementation

void setMousePositionWorld(GraphPosition? position) {
  runInAction(() {
    _mousePositionWorld.value = position?.offset;
  });
}