# HG changeset patch # User bsmith@81767d24-ef19-dc11-ae90-00e081727c95 # Date 1319938874 0 # Node ID 24f1dc19601d30bccbacdfcf0753caf42b6749f9 # Parent 9e477efbacca25f197b0c864bb250fff8d6a4dfb Implemented DW_DRAW_FULL on Windows and implemented DW_DRAW_FILL for ellipses. Fixed not passing DW_DRAW_FULL in the test program. diff -r 9e477efbacca -r 24f1dc19601d dwtest.c --- a/dwtest.c Sun Oct 30 00:40:22 2011 +0000 +++ b/dwtest.c Sun Oct 30 01:41:14 2011 +0000 @@ -376,7 +376,7 @@ /* Bottom left corner */ dw_draw_arc(window, pixmap, 0, 30, height - 30, 30, height - 10, 10, height - 30); /* Full circle in the left top area */ - dw_draw_arc(window, pixmap, 0, 100, 100, 80, 80, 120, 120); + dw_draw_arc(window, pixmap, DW_DRAW_FULL, 100, 100, 80, 80, 120, 120); if(image) { if(image_stretch) diff -r 9e477efbacca -r 24f1dc19601d win/dw.c --- a/win/dw.c Sun Oct 30 00:40:22 2011 +0000 +++ b/win/dw.c Sun Oct 30 01:41:14 2011 +0000 @@ -8843,10 +8843,16 @@ hdcPaint = pixmap->hdc; else return; - - oldBrush = SelectObject( hdcPaint, TlsGetValue(_hBrush) ); + + if(flags & DW_DRAW_FILL) + oldBrush = SelectObject( hdcPaint, TlsGetValue(_hBrush) ); + else + oldBrush = SelectObject( hdcPaint, GetStockObject(HOLLOW_BRUSH) ); oldPen = SelectObject( hdcPaint, TlsGetValue(_hPen) ); - Arc(hdcPaint, xorigin-r, yorigin-r, xorigin+r, yorigin+r, x2, y2, x1, y1); + if(flags & DW_DRAW_FULL) + Ellipse(hdcPaint, x1, y1, x2, y2); + else + Arc(hdcPaint, xorigin-r, yorigin-r, xorigin+r, yorigin+r, x2, y2, x1, y1); SelectObject( hdcPaint, oldBrush ); SelectObject( hdcPaint, oldPen );