blockly > utils > svgMath > screenToWsCoordinates
utils.svgMath.screenToWsCoordinates() function
Converts screen coordinates to workspace coordinates.
Signature:
export declare function screenToWsCoordinates(ws: WorkspaceSvg, screenCoordinates: Coordinate): Coordinate;
Parameters
Parameter | Type | Description |
---|---|---|
ws | WorkspaceSvg | The workspace to find the coordinates on. |
screenCoordinates | Coordinate | The screen coordinates to be converted to workspace coordinates |
Returns:
The workspace coordinates.