forked from 1b-agent/opencadstudio-upstream
feat(cad): integrate standard codec coverage
Render, edit, query, select, and explode newly decoded standard entity variants. Pin acadifc de8d6b5 and preserve None color semantics.
This commit is contained in:
1 parent
34d0c377e2
commit
731df4a725
19 files changed
+484
-72
No files matched your search
@@ -57,6 +57,7 @@ pub fn ui_name(e: &EntityType) -> &'static str {
|
||||
EntityType::Light(_) => "Light",
|
||||
EntityType::SectionSymbol(_) => "Section Symbol",
|
||||
EntityType::ViewBorder(_) => "View Border",
|
||||
EntityType::Extended(_) => "Extended Entity",
|
||||
EntityType::Seqend(_) => "Seqend",
|
||||
EntityType::Unknown(_) => "Unknown",
|
||||
}
|
||||
@@ -68,6 +69,9 @@ pub fn ui_name(e: &EntityType) -> &'static str {
|
||||
/// defers to [`ui_name`]. Falls back to "Unknown" for a class we couldn't name
|
||||
/// (the numeric `DWG_TYPE_<n>` placeholder).
|
||||
pub fn ui_name_or_class(e: &EntityType) -> String {
|
||||
if let EntityType::Extended(entity) = e {
|
||||
return entity.class_name().to_string();
|
||||
}
|
||||
if let EntityType::Unknown(u) = e {
|
||||
let n = u.dxf_name.trim();
|
||||
if !n.is_empty() && !n.starts_with("DWG_TYPE_") {
|
||||
|
||||
Reference in new issue
Block a user