Fix DrawParametricDimension: always regenerate from anchors after RMB

regenerate_dimension was only called when ForcePerpendicularToFace was
set, so normal two-anchor dimensions were left at raw polyline cursor
positions after placement.  The depsgraph handler would later correct
them when the user happened to select a referenced IFC element, making
accurate placement appear to require a manual selection step.

Remove the _force_perpendicular guard so the anchor-based regeneration
always runs at the end of _create_dimension_from_polyline.
This commit is contained in:
Ryan Schultz
2026-06-14 15:09:27 -05:00
parent ffe7296973
commit 5309b4614c
@@ -6242,7 +6242,8 @@ class DrawParametricDimension(bpy.types.Operator, PolylineOperator, tool.Ifc.Ope
pset_props["ForcePerpendicularToFace"] = True pset_props["ForcePerpendicularToFace"] = True
ifcopenshell.api.run("pset.edit_pset", file, pset=pset_entity, properties=pset_props) ifcopenshell.api.run("pset.edit_pset", file, pset=pset_entity, properties=pset_props)
if self._force_perpendicular: # Always regenerate from anchor data so the curve reflects the true IFC
# face positions rather than the raw cursor positions from the polyline.
placement_override: dict = {} placement_override: dict = {}
for a in anchors: for a in anchors:
guid = a.get("guid") guid = a.get("guid")