Arch: endpoint after Wall length change was not in local sketch coords (#9592)

This commit is contained in:
Roy-043
2023-05-16 21:24:16 +02:00
committed by GitHub
parent d4ee459cf2
commit ea35f0f003

View File

@@ -1054,8 +1054,9 @@ class _Wall(ArchComponent.Component):
obj.Base.End = p2
elif Draft.getType(obj.Base) == "Sketcher::SketchObject":
try:
obj.Base.movePoint(0,2,p2,0)
except Exception:
obj.Base.recompute() # Fix for the 'GeoId index out range' error.
obj.Base.movePoint(0, 2, obj.Base.Placement.inverse().multVec(p2))
except Exception: # This 'GeoId index out range' error should no longer occur.
print("Debug: The base sketch of this wall could not be changed, because the sketch has not been edited yet in this session (this is a bug in FreeCAD). Try entering and exiting edit mode in this sketch first, and then changing the wall length should work.")
else:
FreeCAD.Console.PrintError(translate("Arch","Error: Unable to modify the base object of this wall")+"\n")