diff --git a/src/Mod/Draft/draftobjects/dimension.py b/src/Mod/Draft/draftobjects/dimension.py index 1b375eb2da..484fc8e226 100644 --- a/src/Mod/Draft/draftobjects/dimension.py +++ b/src/Mod/Draft/draftobjects/dimension.py @@ -106,8 +106,9 @@ from PySide.QtCore import QT_TRANSLATE_NOOP import FreeCAD as App import DraftVecUtils import DraftGeomUtils -import draftutils.utils as utils +import WorkingPlane +from draftutils import utils from draftutils.messages import _wrn from draftutils.translate import translate @@ -648,10 +649,10 @@ def measure_two_obj_angles(link_sub_1, link_sub_2): start = obj1.Shape.Edges[n1].Curve.Direction end = obj2.Shape.Edges[n2].Curve.Direction - # We get the angle from the direction of the line to the U axis - # of the working plane; we should be able to also use the V axis - start_r = DraftVecUtils.angle(start, App.DraftWorkingPlane.u) - end_r = DraftVecUtils.angle(end, App.DraftWorkingPlane.u) + # We get the angle from the U axis of the working plane + wp = WorkingPlane.get_working_plane(update=False) + start_r = DraftVecUtils.angle(start, wp.u) + end_r = DraftVecUtils.angle(end, wp.u) start = math.degrees(start_r) end = math.degrees(end_r) diff --git a/src/Mod/Draft/drafttaskpanels/task_circulararray.py b/src/Mod/Draft/drafttaskpanels/task_circulararray.py index 0a58701875..f3f7f17e8b 100644 --- a/src/Mod/Draft/drafttaskpanels/task_circulararray.py +++ b/src/Mod/Draft/drafttaskpanels/task_circulararray.py @@ -392,10 +392,8 @@ class TaskPanelCircularArray: point: Base::Vector3 is a vector that arrives by the callback. - plane: WorkingPlane - is a `WorkingPlane` instance, for example, - `App.DraftWorkingPlane`. It is not used at the moment, - but could be used to set up the grid. + plane: WorkingPlane.PlaneGui + is a working plane instance. Not used at the moment. mask: str is a string that specifies which coordinate is being edited. It is used to restrict edition of a single coordinate. diff --git a/src/Mod/Draft/drafttaskpanels/task_polararray.py b/src/Mod/Draft/drafttaskpanels/task_polararray.py index 81e3f8227e..f4888bd0e1 100644 --- a/src/Mod/Draft/drafttaskpanels/task_polararray.py +++ b/src/Mod/Draft/drafttaskpanels/task_polararray.py @@ -346,9 +346,7 @@ class TaskPanelPolarArray: point : is a vector that arrives by the callback. plane : - is a `WorkingPlane` instance, for example, - `App.DraftWorkingPlane`. It is not used at the moment, - but could be used to set up the grid. + is a `WorkingPlane.PlaneGui` instance. Not used at the moment. mask : is a string that specifies which coordinate is being edited. It is used to restrict edition of a single coordinate.