From 19e4113de4a3f63705f64702f4d464a2566fae1b Mon Sep 17 00:00:00 2001 From: Yorik van Havre Date: Mon, 1 Mar 2021 16:49:31 +0100 Subject: [PATCH] Arch: Fixed SectionPlane outside objects bug in ArchSectionPlane - Fixes #4549 --- src/Mod/Arch/ArchSectionPlane.py | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/Mod/Arch/ArchSectionPlane.py b/src/Mod/Arch/ArchSectionPlane.py index b38354a6eb..ba04ede52b 100644 --- a/src/Mod/Arch/ArchSectionPlane.py +++ b/src/Mod/Arch/ArchSectionPlane.py @@ -211,11 +211,11 @@ def getCutShapes(objs,cutplane,onlySolids,clip,joinArch,showHidden,groupSshapesB cutface,cutvolume,invcutvolume = ArchCommands.getCutVolume(cutplane,shapes,clip) shapes = [] - if cutvolume: - for o, shapeList in objectShapes: - tmpSshapes = [] - for sh in shapeList: - for sol in sh.Solids: + for o, shapeList in objectShapes: + tmpSshapes = [] + for sh in shapeList: + for sol in sh.Solids: + if cutvolume: if sol.Volume < 0: sol.reverse() c = sol.cut(cutvolume) @@ -235,6 +235,8 @@ def getCutShapes(objs,cutplane,onlySolids,clip,joinArch,showHidden,groupSshapesB if showHidden: c = sol.cut(invcutvolume) hshapes.append(c) + else: + shapes.extend(sol.Solids) if len(tmpSshapes) > 0: sshapes.extend(tmpSshapes)