Guide sketch patterns with live previews and editable offsets (#966)
Sketch Mirror, rectangular and circular Pattern, and Offset now show a green live preview that follows the selection and settings; OK commits, Cancel leaves the sketch unchanged. The shared dialogs show the current selection step and source counts, sources can be toggled with Ctrl/Cmd-click, cleared and reselected. Offsets keep editable driving distance dimensions (One Side, Two Sides, Symmetric) that update the derived curves without moving the source, with undo/redo and save/reopen. Format 19: older files keep their fixed offsets. New dialog labels in en, zh, ja, de and ko. Fixes #696. Fixes #517.
This commit is contained in:
1 parent
9c51f9d433
commit
47a7f29485
29 files changed
+1107
-186
No files matched your search
@@ -2204,6 +2204,13 @@ fn sketch_delete(s: &mut Session, p: &Value) -> Result<Value> {
|
||||
return Err(bad(cmd, "break the offset association before deleting only part of its curved boundary"));
|
||||
}
|
||||
}
|
||||
if sk.constraints.iter().any(|c| cons.contains(&c.id) && matches!(c.kind, ConstraintKind::OffsetDistance { .. })) {
|
||||
let report = solve_current(sk, doc)?;
|
||||
if !report.keeps_orientation() {
|
||||
return Err(bad(cmd, "cannot remove an offset dimension from a conflicting sketch"));
|
||||
}
|
||||
sk.refresh_offsets()?;
|
||||
}
|
||||
sk.constraints.retain(|c| !cons.contains(&c.id));
|
||||
let pids: Vec<String> = points.iter().filter_map(|q| sk.points.get(*q).map(|x| x.id.clone())).collect();
|
||||
sk.remove_curves(&curves);
|
||||
|
||||
Reference in new issue
Block a user