From 10a99f20aa2e631c7ed9271a26e8aaa9e7db84ca Mon Sep 17 00:00:00 2001 From: Stefan Csomor Date: Tue, 27 May 2008 04:57:52 +0000 Subject: [PATCH] fixing arc filling for angles > 180 git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_8_BRANCH@53772 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/common/dcgraph.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/common/dcgraph.cpp b/src/common/dcgraph.cpp index 82abf02b33..95c750178b 100644 --- a/src/common/dcgraph.cpp +++ b/src/common/dcgraph.cpp @@ -539,14 +539,12 @@ void wxGCDC::DoDrawEllipticArc( wxCoord x, wxCoord y, wxCoord w, wxCoord h, { wxGraphicsPath path = m_graphicContext->CreatePath(); path.MoveToPoint( 0, 0 ); - path.AddLineToPoint( h / 2.0 * cos(DegToRad(sa)) , h / 2.0 * sin(DegToRad(-sa)) ); - path.AddLineToPoint( h / 2.0 * cos(DegToRad(ea)) , h / 2.0 * sin(DegToRad(-ea)) ); + path.AddArc( 0, 0, h/2.0 , DegToRad(-sa) , DegToRad(-ea), sa > ea ); path.AddLineToPoint( 0, 0 ); m_graphicContext->FillPath( path ); path = m_graphicContext->CreatePath(); path.AddArc( 0, 0, h/2.0 , DegToRad(-sa) , DegToRad(-ea), sa > ea ); - m_graphicContext->FillPath( path ); m_graphicContext->StrokePath( path ); } else