(pos: QPointF)
| 18 | |
| 19 | |
| 20 | def snap(pos: QPointF) -> QPointF: |
| 21 | x = round(pos.x() / GRID_SIZE) * GRID_SIZE |
| 22 | y = round(pos.y() / GRID_SIZE) * GRID_SIZE |
| 23 | return QPointF(x, y) |
| 24 | |
| 25 | |
| 26 | # ── canvas stacking order (Z-values) ────────────────────────────────────────── |
no outgoing calls
no test coverage detected