forked from 1b-agent/opencadstudio-upstream
revert: drop PLOTWINDOW forced endpoint snap (#293)
Remove the forces_endpoint_snap mechanism merged in #293: CadCommand::forces_endpoint_snap, Snapper::snap_forced_corners / forced_corner_modes, the PlotWindowCommand override, the on_tick + click-commit wiring, and the associated tests. PLOTWINDOW now uses the normal snapper like every other command. Rationale: forcing Endpoint snap on regardless of the global OSNAP master overrides an explicit user setting and is surprising — a plot window is a coarse print region that usually wants a margin, not a corner lock, and the forced set only caught Endpoint (not center/mid/intersection) so it was a partial, opinionated helper. Parking it pending a design discussion with the PR author; can be reinstated behind a clearer UX (e.g. respecting OSNAP, or an opt-in modifier) if justified. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
1 parent
cb41910f12
commit
9490c85b32
4 files changed
+3
-138
No files matched your search
@@ -530,13 +530,6 @@ pub trait CadCommand: Send {
|
||||
false
|
||||
}
|
||||
|
||||
/// True if this command should have Endpoint/Intersection object-snap
|
||||
/// forced on while it is active, regardless of the global OSNAP toggle.
|
||||
/// Used by PLOTWINDOW so the plot-area corners always snap to geometry.
|
||||
fn forces_endpoint_snap(&self) -> bool {
|
||||
false
|
||||
}
|
||||
|
||||
/// Called when the text editor closes, either because the user committed or cancelled the edit.
|
||||
fn on_editor_closed(&mut self, _committed: bool) -> CmdResult {
|
||||
CmdResult::Cancel
|
||||
|
||||
Reference in new issue
Block a user