Align BOX properties and history controls

This commit is contained in:
ramox81 committed 2026-08-28 16:36:46 +03:00
1 parent e7eb487cd8
commit 27f648d2bb
4 files changed
+307 -13

No files matched your search

+22 -7
View File
@@ -434,8 +434,21 @@ impl OpenCADStudio {
let display_entity = dispatch::entity_in_working_plane(contextual.as_ref(), plane);
let entity = &display_entity;
let group_names = self.tabs[i].scene.group_names_for_entity(handle);
let box_primitive =
crate::scene::model::solid_history::is_box_primitive(
&self.tabs[i].scene.document,
handle,
);
let mut sections =
dispatch::properties_sectioned(handle, entity, &text_style_names);
if box_primitive {
sections.retain(|section| {
!section.props.iter().any(|property| {
property.field.starts_with("acis_")
|| property.field.starts_with("s3d_")
})
});
}
sections.extend(
crate::scene::model::solid_history::primitive_properties(
&self.tabs[i].scene.document,
@@ -600,7 +613,7 @@ impl OpenCADStudio {
}
}
if matches!(
if !box_primitive && matches!(
entity,
acadrust::EntityType::Solid3D(_)
| acadrust::EntityType::Region(_)
@@ -674,12 +687,14 @@ impl OpenCADStudio {
}
}
sections.extend(crate::entities::object_data::sections(
&self.tabs[i].scene.document,
&self.tabs[i].scene.object_data_cache,
handle,
entity,
));
if !box_primitive {
sections.extend(crate::entities::object_data::sections(
&self.tabs[i].scene.document,
&self.tabs[i].scene.object_data_cache,
handle,
entity,
));
}
{
use crate::entities::common::ro_prop;
+10 -1
View File
@@ -1900,7 +1900,16 @@ pub(super) fn on_tab_close(&mut self, idx: usize) -> Task<Message> {
}
self.push_undo_snapshot(i, "CHPROP");
if field == "tol_text_style" {
if crate::scene::model::solid_history::is_history_choice(field) {
for &handle in &handles {
if self.tabs[i].scene.is_layer_locked(handle) {
continue;
}
self.tabs[i]
.scene
.apply_solid_history_choice(handle, field, &value);
}
} else if field == "tol_text_style" {
use crate::entities::dim_override as dov;
use acadrust::xdata::XDataValue;
let style_handle = self.tabs[i]