Insert ribbon: Import panel

Import File split button (PDF Import / DGN Import / Import), Recognize
SHX Text, Recognition Settings and Combine Text; Land XML moves to the
panel slide-out and Open leaves the panel. Ribbon commands may be menu
macros (`;` answers the running command's prompt). KeyTips IF, PI, DI,
OI, PS, PT, TM; labels in every locale.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
ramox81andClaude Opus 5.5 committed 2026-10-15 14:53:08 +03:00
1 parent 39c3e9af58
commit 8a87a09e30
33 files changed
+326 -41

No files matched your search

+19
View File
@@ -107,6 +107,25 @@ impl OpenCADStudio {
task
}
/// Run a ribbon command. A `;` stands for Enter, as in a menu macro: each
/// part answers the running command's prompt, or starts a command when
/// none runs (`PDFIMPORT;FILE`).
pub(super) fn dispatch_ribbon_command(&mut self, cmd: &str) -> Task<Message> {
if !cmd.contains(';') {
return self.dispatch_command(cmd);
}
let i = self.active_tab;
let mut tasks = Vec::new();
for part in cmd.split(';') {
tasks.push(if self.tabs[i].active_cmd.is_some() {
self.feed_active_cmd(part)
} else {
self.dispatch_command(part)
});
}
Task::batch(tasks)
}
/// Turn the ribbon highlight off when the command just dispatched left
/// nothing running: no interactive command, dialog or navigation mode.
/// One-shot commands (view changes, clipboard, toggles, audits…) would
+1 -1
View File
@@ -133,7 +133,7 @@ impl OpenCADStudio {
match event {
// `dispatch_command` turns a one-shot tool's highlight off
// again once nothing is left running (#355).
ModuleEvent::Command(cmd) => return self.dispatch_command(&cmd),
ModuleEvent::Command(cmd) => return self.dispatch_ribbon_command(&cmd),
ModuleEvent::OpenFileDialog => {
self.command_line
.push_info(crate::t!("Open DWG/DXF: not yet implemented.").as_ref());
+1 -1
View File
@@ -6613,7 +6613,7 @@ impl OpenCADStudio {
};
self.ribbon.select_dropdown_item(dropdown_id, face);
self.ribbon.activate_tool(cmd);
self.dispatch_command(cmd)
self.dispatch_ribbon_command(cmd)
}
Message::DeleteSelected => {