Skip to content

Commit

Permalink
[Draft] Cleaned code in arc 3Points preview
Browse files Browse the repository at this point in the history
Arc tracker during creation is computed by arc tracker new method.
  • Loading branch information
carlopav authored and yorikvanhavre committed Jun 27, 2019
1 parent 87225f0 commit e7e3550
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions src/Mod/Draft/DraftTools.py
Expand Up @@ -5569,17 +5569,9 @@ def getPoint(self,point,info):
FreeCAD.ActiveDocument.recompute()

def drawArc(self,point,info):

if len(self.points) == 2:
import Part
if point.sub(self.points[1]).Length > 0.001:
e = Part.Arc(self.points[0],self.points[1],point).toShape()
self.tracker.normal = e.Curve.Axis.negative() # for some reason the axis always points "backwards"
self.tracker.basevector = self.tracker.getDeviation()
self.tracker.setCenter(e.Curve.Center)
self.tracker.setRadius(e.Curve.Radius)
self.tracker.setStartPoint(self.points[0])
self.tracker.setEndPoint(point)
self.tracker.setBy3Points(self.points[0],self.points[1],point)


#---------------------------------------------------------------------------
Expand Down

0 comments on commit e7e3550

Please sign in to comment.