diff --git a/test/drawtests.c b/test/drawtests.c index d2c3a2af..d38c8891 100644 --- a/test/drawtests.c +++ b/test/drawtests.c @@ -81,7 +81,7 @@ static void drawOriginal(uiAreaDrawParams *p) 50, 30. * (M_PI / 180.), 300. * (M_PI / 180.)); - // TODO add a checkbox for this + // the sweep test below doubles as a clockwise test so a checkbox isn't needed anymore uiDrawPathLineTo(path, 400, 100); uiDrawPathNewFigureWithArc(path, 510, 100, @@ -89,6 +89,20 @@ static void drawOriginal(uiAreaDrawParams *p) 30. * (M_PI / 180.), 300. * (M_PI / 180.)); uiDrawPathCloseFigure(path); + // and now with 330 to make sure sweeps work properly + uiDrawPathNewFigure(path, 400, 210); + uiDrawPathArcTo(path, + 400, 210, + 50, + 30. * (M_PI / 180.), + 330. * (M_PI / 180.)); + uiDrawPathLineTo(path, 400, 210); + uiDrawPathNewFigureWithArc(path, + 510, 210, + 50, + 30. * (M_PI / 180.), + 330. * (M_PI / 180.)); + uiDrawPathCloseFigure(path); uiDrawPathEnd(path); sp.Cap = uiDrawLineCapFlat; sp.Join = uiDrawLineJoinMiter; @@ -170,6 +184,7 @@ static void drawOriginal(uiAreaDrawParams *p) uiDrawFreePath(path); } +// TODO test that a sweep of 0 draws nothing static void drawArcs(uiAreaDrawParams *p) { uiDrawPath *path;