From 3ddc7dfd41d5d85dd950142ad9a6ec9e66d90086 Mon Sep 17 00:00:00 2001 From: John Date: Tue, 14 Jan 2014 17:28:11 +0000 Subject: [PATCH] Fixed the code to handle a radius of zero during the curve calculations --- PROMS/XYPlots/XYPlots.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/PROMS/XYPlots/XYPlots.cs b/PROMS/XYPlots/XYPlots.cs index acfdf997..d0eaa540 100644 --- a/PROMS/XYPlots/XYPlots.cs +++ b/PROMS/XYPlots/XYPlots.cs @@ -1202,7 +1202,7 @@ namespace XYPlots { double tprime; tprime = FixAngle(thetaa); - if (Math.Abs(tprime - t3) < ANGLELIMIT) + if (Math.Abs(tprime - t3) <= ANGLELIMIT) { MoveTo(pt1.APoint); DrawTo(pt2.APoint, pg, vgOutput); @@ -1374,7 +1374,7 @@ namespace XYPlots //DebugOutput("DrawArc5"); VG_Arc.iColor = 5; //VG_Arc.iColor = 6; //#endif - DrawArc(r2, t2, t2 - theta2, cp2, x, y, pg, vgOutput); + if (r2 != 0) DrawArc(r2, t2, t2 - theta2, cp2, x, y, pg, vgOutput); DebugShowLocation("DrawArc5"); } //DebugOutput(""); VG_Arc.iColor = 6;