Skip to content

SolidCraft: an open-source parametric 3D CAD application built in pure Rust. Desktop, web, and automation through MCP.

2.3 KB
Raw Blame
[
 {"note": "sketch.scale drew a toolbar button that reached no tool and no dialog, so a press ran the command with no parameters at all and the engine answered \"`factor` must be a positive number\". It now opens a tool window carrying Entities, a Base point and a Factor."},
 {"start": "sketch.create"},
 {"click": {"plane": "XY"}},
 {"expect": {"sketching": true}},
 {"start": "sketch.rectangle.two_point"},
 {"click": {"sketch": [0, 0]}},
 {"click": {"sketch": [20, 10]}},
 {"key": "Escape"},
 {"expect": {"sketch_curves": {"own": 4}, "errors": 0}},
 {"expect": {"query": {"command": "sketch.inspect", "path": ["profiles", 0, "area_mm2"], "value": 200}}},

 {"note": "The dead-button regression: the press opens a window, commits nothing and reports nothing. A pick fills the input and still commits nothing."},
 {"start": "sketch.scale"},
 {"expect": {"dialog": "SketchModify(Scale", "sketch_curves": {"own": 4}, "errors": 0}},
 {"click": {"sketch": [10, 0]}},
 {"expect": {"dialog": "SketchModify(Scale", "sketch_curves": {"own": 4}, "errors": 0}},
 {"expect": {"query": {"command": "sketch.inspect", "path": ["profiles", 0, "area_mm2"], "value": 200}}},

 {"note": "Escape leaves the sketch exactly as it was."},
 {"key": "Escape"},
 {"expect": {"dialog": null, "errors": 0, "sketch_curves": {"own": 4}}},
 {"expect": {"query": {"command": "sketch.inspect", "path": ["profiles", 0, "area_mm2"], "value": 200}}},

 {"note": "The typed factor reaches the command unchanged: all four sides picked and 2 typed doubles the rectangle about the sketch origin, so its area goes from 200 to 800 mm2 and its far corner from (20, 10) to (40, 20)."},
 {"start": "sketch.scale"},
 {"click": {"sketch": [10, 0]}},
 {"click": {"sketch": [20, 5]}},
 {"click": {"sketch": [10, 10]}},
 {"click": {"sketch": [0, 5]}},
 {"click": {"handle": "dialog:Factor"}},
 {"key": "A", "cmd": true},
 {"text": "2"},
 {"key": "Enter"},
 {"expect": {"dialog": null, "errors": 0, "sketch_curves": {"own": 4}}},
 {"expect": {"query": {"command": "sketch.inspect", "path": ["profiles", 0, "area_mm2"], "value": 800}}},
 {"shot": "sketch_scale_window"},

 {"note": "Starting the command again and pressing Escape leaves the document and the undo history untouched."},
 {"start": "sketch.scale"},
 {"expect": {"dialog": "SketchModify(Scale"}},
 {"key": "Escape"},
 {"expect": {"dialog": null, "errors": 0}}
]