Draft: fix display of Building US dim text (#23674)

* Draft: fix display of Building US dim text

* Fix UnitSystem check
This commit is contained in:
Roy-043
2025-09-08 14:35:21 +02:00
committed by GitHub
parent 41358863f6
commit b8f5e6848c

View File

@@ -588,7 +588,9 @@ class ViewProviderLinearDimension(ViewProviderDimensionBase):
unit = vobj.UnitOverride
# Special representation if we use 'Building US' scheme
if (not unit and params.get_param("UserSchema", path="Units") == 5) or (unit == "arch"):
doc = obj.Document
if (not unit and doc.UnitSystem == doc.getEnumerationsOfProperty("UnitSystem")[5]) \
or (unit == "arch"):
self.string = App.Units.Quantity(length, App.Units.Length).UserString
if self.string.count('"') > 1:
# multiple inch tokens