utils.svgMath namespace
Functions
Function | Description |
---|---|
getDocumentScroll() | Gets the document scroll distance as a coordinate object. Copied from Closure's goog.dom.getDocumentScroll. |
getInjectionDivXY(element) | Return the coordinates of the top-left corner of this element relative to the div Blockly was injected into. |
getRelativeXY(element) | Return the coordinates of the top-left corner of this element relative to its parent. Only for SVG elements and children (e.g. rect, g, path). |
screenToWsCoordinates(ws, screenCoordinates) | Converts screen coordinates to workspace coordinates. |
wsToScreenCoordinates(ws, workspaceCoordinates) | Converts workspace coordinates to screen coordinates. |
Variables
Variable | Description |
---|---|
TEST_ONLY |