feat(view): zoom-window ribbon button and bare ZOOM command

Bare `ZOOM` had no dispatch arm — only the sub-keyword forms (ZOOM
EXTENTS/IN/OUT/WINDOW/…) were handled, so typing `ZOOM` fell through to
an unknown-command error. It now starts the interactive window zoom.

Add the missing Zoom Window ribbon button: the command existed but had no
tool()/icon, so it was reachable only by typing. Wire it into View ▸
Navigate with a new dashed-rectangle magnifier icon.

Closes #210

Co-Authored-By: Claude Opus 4.8 <[email protected]>
This commit is contained in:
Hakan SevenandClaude Opus 4.8 committed 2026-06-28 16:57:00 +03:00
1 parent ccd249d40f
commit 9928cbf0e5
4 files changed
+24 -1

No files matched your search

+4 -1
View File
@@ -304,7 +304,10 @@ impl OpenCADStudio {
self.tabs[i].active_cmd = Some(Box::new(cmd));
}
"ZOOM WINDOW" | "ZOOM W" | "ZW" => {
// Bare ZOOM enters the interactive window zoom (pick two corners) —
// the common "zoom to a rectangle" action. The sub-keyword forms
// (ZOOM EXTENTS / IN / OUT / …) are matched above.
"ZOOM WINDOW" | "ZOOM W" | "ZW" | "ZOOM" => {
use crate::modules::view::zoom_window::ZoomWindowCommand;
let new_cmd = ZoomWindowCommand::new();
self.command_line.push_info(&new_cmd.prompt());