Drawing connects to existing points: a new point landing exactly on an existing point (the origin too) gets a coincident constraint in the engine, for every drawing command and every caller (MCP, scripts, clicks), in the same undo step; connect: false opts out. Re-tying an existing coincident returns it ("existing": true) instead of failing; the UI's after-the-fact tie_snaps is gone

This commit is contained in:
CypherNaugh_0x authored and bherbruck committed 2026-10-10 12:08:19 -04:00
1 parent 448ea769eb
commit 5d5ff44db2
8 files changed
+141 -66

No files matched your search

@@ -0,0 +1,14 @@
[
{"note": "A rectangle whose first corner is clicked on the origin is tied to it once (the engine connects it), so two dimensions fully constrain it."},
{"start": "sketch.create"},
{"click": {"plane": "XY"}},
{"start": "sketch.rectangle.two_point"},
{"click": {"sketch": [0, 0]}},
{"click": {"sketch": [30, 20]}},
{"key": "Escape"},
{"expect": {"query": {"command": "sketch.inspect", "path": ["dof"], "value": 2}}},
{"expect": {"query": {"command": "sketch.inspect", "path": ["constraints", 4, "type"], "value": "coincident"}}},
{"expect": {"query": {"command": "sketch.inspect", "path": ["constraints", 5], "value": null}}},
{"key": "Z", "cmd": true},
{"expect": {"query": {"command": "sketch.inspect", "path": ["curves", 0], "value": null}}}
]