utils.svgMath 命名空間
函式
| 函式 | 說明 |
|---|---|
| getDocumentScroll() | 取得文件捲動距離,以座標物件表示。從 Closure 的 goog.dom.getDocumentScroll 複製過來。 |
| getInjectionDivXY(元素) | 傳回此元素左上角的座標 (相對於插入 div Blockly 的情況)。 |
| getRelativeXY(元素) | 傳回這個元素的左上角座標 (相對於父項)。僅適用於 SVG 元素和子項 (例如矩形、g、path)。 |
| screenToWsCoordinates(ws, screenCoordinates) | 將螢幕座標轉換為工作區座標。 |
| wsToScreenCoordinates(ws, workspaceCoordinates) | 將工作區座標轉換為螢幕座標。 |
Variables
| 變數 | 說明 |
|---|---|
| TEST_ONLY |