forked from 1b-agent/opencadstudio-upstream
Fix jogged radius properties and layout
This commit is contained in:
1 parent
ba91095bcf
commit
7b58de2578
3 files changed
+328
-30
No files matched your search
Vendored
+5
-13
@@ -73,6 +73,11 @@ pub fn general_section(entity: &EntityType) -> PropSection {
|
||||
field: "lineweight",
|
||||
value: PropValue::LwChoice(common.line_weight),
|
||||
},
|
||||
Property {
|
||||
label: t!("Hyperlink").into_owned(),
|
||||
field: "hyperlink",
|
||||
value: PropValue::PlainText(hyperlink),
|
||||
},
|
||||
Property {
|
||||
label: t!("Transparency").into_owned(),
|
||||
field: "transparency",
|
||||
@@ -81,22 +86,9 @@ pub fn general_section(entity: &EntityType) -> PropSection {
|
||||
options: vec!["ByLayer".to_string(), "ByBlock".to_string()],
|
||||
},
|
||||
},
|
||||
Property {
|
||||
label: t!("Hyperlink").into_owned(),
|
||||
field: "hyperlink",
|
||||
value: PropValue::PlainText(hyperlink),
|
||||
},
|
||||
],
|
||||
};
|
||||
|
||||
if matches!(entity, EntityType::Point(_)) {
|
||||
let hyperlink = section.props.iter().position(|prop| prop.field == "hyperlink");
|
||||
let transparency = section.props.iter().position(|prop| prop.field == "transparency");
|
||||
if let (Some(hyperlink), Some(transparency)) = (hyperlink, transparency) {
|
||||
section.props.swap(hyperlink, transparency);
|
||||
}
|
||||
}
|
||||
|
||||
// Thickness (DXF 39) is a General-group property, but only the entity
|
||||
// types that carry an extrusion thickness expose it (line, circle, arc,
|
||||
// polyline, text, 2D solid, …). Show it right after Hyperlink for those.
|
||||
|
||||
Reference in new issue
Block a user