fix: open-issue sweep — drawing, plot, snap, layout and UI fixes

Fixes:
- Font prompt no longer lists bundled ltypeshp/qcadshp shape files (#1626)
- Wide polylines step at a discontinuous segment width; PEDIT marks the
  current vertex; keyword steps refresh the command preview (#1628)
- Radius-0 fillet drops the zero-length segment it left, so the corner
  fillets again (#1422)
- FILLET Trim / No trim option (#1558)
- True-colour wires plot in their own colour; colour picker stores the
  value it shows (#1621)
- Model tab keeps its page setup; "Save changes to layout" in Model (#1620)
- QNEW default template in Options > Files; .dwt in the open dialog
  (#1134, #1113)
- GRIDUNIT / GRIDMODE / PERSPECTIVE variables (#1618, #1524)
- PTYPE (#1433)
- ZOOM nX / nXP (#1465)
- CHSPACE between model and paper space through a viewport (#1428)
- Moving a dimension keeps its automatic text placement
- Shell icon; "&&" button labels (#1554)
- LINETYPE Load from a .lin file (#1588)
- XLINE / RAY hide the crosshair arms (#1437)
- Dynamic-input boxes keep clear of the crosshair and each other (#1546)
- Snap marker colour setting, dark default on light canvases
  (#1497, #1229, #1128)
- Dimension style precision as a 0.00 pattern dropdown (#1426)
- Node graph nodes left of the origin no longer clip away (#1592)
- Collapse button in the command history header (#1094)
- Freeze-in-current-viewport toggle in the ribbon layer list (#1466)
- Geometric Center object snap for closed polylines (#1369)

New strings translated in all 21 locales.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Hakan SevenandClaude Opus 5.5 committed 2026-10-06 15:59:30 +03:00
1 parent abf302eba5
commit 178c7dff41
70 files changed
+1227 -145

No files matched your search

+1
View File
@@ -1311,6 +1311,7 @@ pub(super) fn on_tab_close(&mut self, idx: usize) -> Task<Message> {
self.tabs[i]
.layers
.sync_with_viewports(&doc_layers, vp_info);
self.sync_ribbon_layers();
// Per-viewport layer visibility changes the resident
// assembly, not any entity's tessellated geometry.
self.tabs[i].scene.bump_geometry_no_blocks();
+13 -2
View File
@@ -681,6 +681,7 @@ impl OpenCADStudio {
ncopy_bind: self.ncopy_bind,
cursor_type: self.cursor_type,
crosshair_color: self.crosshair_color,
snap_marker_color: self.snap_marker_color,
lineweight_display_scale: self.lineweight_display_scale,
isometric_drafting: self.isometric_drafting,
iso_plane: self.iso_plane,
@@ -689,6 +690,7 @@ impl OpenCADStudio {
default_assoc_prompted: self.default_assoc_prompted,
check_missing_fonts: self.check_missing_fonts,
font_source_url: self.font_source_url.clone(),
qnew_template: self.qnew_template.clone(),
donation_prompt_version: self.donation_prompt_version.clone(),
gpu_warning_silenced: self.gpu_warning_silenced.clone(),
disabled_plugins: {
@@ -791,6 +793,11 @@ impl OpenCADStudio {
.crosshair_color
.map(crate::app::config::rgb_to_hex)
.unwrap_or_default();
self.snap_marker_color = s.snap_marker_color;
self.snap_marker_color_input = s
.snap_marker_color
.map(crate::app::config::rgb_to_hex)
.unwrap_or_default();
self.lineweight_display_scale = s.lineweight_display_scale.clamp(25, 200);
self.isometric_drafting = s.isometric_drafting;
self.iso_plane = s.iso_plane;
@@ -808,6 +815,7 @@ impl OpenCADStudio {
self.default_assoc_prompted = s.default_assoc_prompted;
self.check_missing_fonts = s.check_missing_fonts;
self.font_source_url = s.font_source_url.clone();
self.qnew_template = s.qnew_template.clone();
self.font_source_input = s.font_source_url.clone();
self.donation_prompt_version = s.donation_prompt_version.clone();
self.gpu_warning_silenced = s.gpu_warning_silenced.clone();
@@ -3603,10 +3611,13 @@ impl OpenCADStudio {
pub(super) fn apply_plot_page_settings(&mut self) {
let i = self.active_tab;
let layout_name = self.tabs[i].scene.current_layout.clone();
let ps = self.plot_settings_from_dialog(self.dialog_base_settings());
if layout_name == "Model" {
// Model keeps its page setup too (#1620); it has no sheet limits.
self.tabs[i].scene.set_layout_plot_settings(&layout_name, &ps);
self.tabs[i].dirty = true;
return;
}
let ps = self.plot_settings_from_dialog(self.dialog_base_settings());
let (w, h) = plot_dialog_sheet_mm(&self.plot_dialog);
let plot_area = self.plot_dialog.area.clone();
let center = ps.flags.plot_centered;
@@ -5360,7 +5371,7 @@ impl OpenCADStudio {
// into it when "Save changes to layout" is on, so the page setup
// remembers the last plot the way other applications expect. The
// runtime paper/scale choices drive this one plot operation either way.
if !preview && d.save_to_layout && d.paper_space {
if !preview && d.save_to_layout {
self.apply_dialog_to_layout();
} else {
self.sync_dialog_plot_runtime();
+67
View File
@@ -1877,6 +1877,20 @@ impl OpenCADStudio {
self.sync_ribbon_from_selection();
// A fresh drawing starts with grid/snap off (its tile defaults).
self.adopt_view_display(self.active_tab);
// QNEW: start from the default template when one is set (#1113).
let template = self.qnew_template.trim().to_string();
if !template.is_empty() {
match self.apply_template(&template) {
Ok(_) => {
self.tabs[idx].dirty = false;
self.refresh_layer_panel();
self.sync_ribbon_styles();
}
Err(error) => self.command_line.push_error(
error["error"].as_str().unwrap_or("template"),
),
}
}
Task::none()
}
@@ -5809,6 +5823,10 @@ impl OpenCADStudio {
if id == crate::modules::insert::insert_block::GALLERY_ID {
self.refresh_block_palette();
}
// The per-viewport freeze column follows the active viewport.
if id == crate::ui::ribbon::widgets::LAYER_COMBO_ID {
self.refresh_layer_panel();
}
self.ribbon.toggle_dropdown(&id);
}
Task::none()
@@ -8005,6 +8023,39 @@ impl OpenCADStudio {
Task::none()
}
Message::QnewTemplateChanged(path) => {
self.qnew_template = path;
self.persist_settings_if_changed();
Task::none()
}
Message::QnewTemplateBrowse => Task::perform(
async {
crate::sys::file_dialog()
.add_filter(
crate::t!("Drawing Template (*.dwt)").as_ref(),
&["dwt", "DWT", "dwg", "DWG", "dxf", "DXF"],
)
.pick_file()
.await
.map(|handle| crate::sys::handle_path(&handle).display().to_string())
},
|path| match path {
Some(path) => Message::QnewTemplateChanged(path),
None => Message::Noop,
},
),
Message::SnapMarkerColorChanged(value) => {
self.snap_marker_color_input = value.clone();
if value.trim().is_empty() {
self.snap_marker_color = None;
self.persist_settings_if_changed();
} else if let Some(rgb) = crate::app::config::parse_hex(&value) {
self.snap_marker_color = Some(rgb);
self.persist_settings_if_changed();
}
Task::none()
}
Message::DefaultSaveFormatChanged(format) => {
self.default_save_format = crate::io::canonical_save_format(&format).to_string();
self.persist_settings_if_changed();
@@ -9835,6 +9886,22 @@ impl OpenCADStudio {
}
// ── Plot Style Table ──────────────────────────────────────────────
Message::LinetypeLoaded(Some(source)) => {
let i = self.active_tab;
self.push_undo_snapshot(i, "LINETYPE");
let added = crate::io::linetypes::populate_document_from_source(
&mut self.tabs[i].scene.document,
&source,
);
if added > 0 {
self.tabs[i].dirty = true;
self.tabs[i].scene.bump_geometry();
}
self.command_line
.push_output(crate::tf!("{added} linetype(s) loaded.").as_ref());
Task::none()
}
Message::LinetypeLoaded(None) => Task::none(),
Message::PlotStyleLoad => {
Task::perform(crate::io::pick_plot_style(), Message::PlotStyleLoaded)
}