From d9e7ee46e67e415a8bde508db7b43f1b42e6abb0 Mon Sep 17 00:00:00 2001 From: Amritpal Singh Date: Thu, 4 Feb 2021 22:53:41 +0530 Subject: [PATCH] Draft: Fix bug in getCubicDimensions function --- src/Mod/Draft/draftgeoutils/cuboids.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Mod/Draft/draftgeoutils/cuboids.py b/src/Mod/Draft/draftgeoutils/cuboids.py index 9de283a152..833e46634c 100644 --- a/src/Mod/Draft/draftgeoutils/cuboids.py +++ b/src/Mod/Draft/draftgeoutils/cuboids.py @@ -99,6 +99,8 @@ def getCubicDimensions(shape): # getting length and width vx = vec(base.Edges[0]) vy = vec(base.Edges[1]) + if round(vx.Length) == round(vy.Length): + vy = vec(base.Edges[2]) # getting rotations rotZ = DraftVecUtils.angle(vx)