Mercurial > dwindows
diff os2/dw.c @ 1290:d2c4deea6bf6
Simplified fill for ellipses and circles on OS/2 using DRO_OUTLINEFILL.
author | bsmith@81767d24-ef19-dc11-ae90-00e081727c95 |
---|---|
date | Mon, 31 Oct 2011 11:36:31 +0000 |
parents | 6a5df80cfb43 |
children | b99b0b2c2826 |
line wrap: on
line diff
--- a/os2/dw.c Mon Oct 31 11:04:03 2011 +0000 +++ b/os2/dw.c Mon Oct 31 11:36:31 2011 +0000 @@ -8700,10 +8700,6 @@ else return; - /* For a filled arc we need to start an area */ - if(flags & DW_DRAW_FILL) - GpiBeginArea(hps, 0L); - /* Handle full circle/ellipse */ if(flags & DW_DRAW_FULL) { @@ -8714,10 +8710,14 @@ ap.lQ = (y2 - y1)/2; /* Setup the arc info on the presentation space */ GpiSetArcParams(hps, &ap); - GpiFullArc(hps, DRO_OUTLINE, MAKEFIXED(1, 1)); + GpiFullArc(hps, (flags & DW_DRAW_FILL) ? DRO_OUTLINEFILL : DRO_OUTLINE, MAKEFIXED(1, 1)); } else { + /* For a filled arc we need to start an area */ + if(flags & DW_DRAW_FILL) + GpiBeginArea(hps, 0L); + /* Setup the default arc info on the presentation space */ GpiSetArcParams(hps, &ap); pts[0].x = x1; @@ -8739,9 +8739,9 @@ pts[1].y = thisheight - y2 - 1; /* Actually draw the arc */ GpiPointArc(hps, pts); - } - if(flags & DW_DRAW_FILL) - GpiEndArea(hps); + if(flags & DW_DRAW_FILL) + GpiEndArea(hps); + } if(!pixmap) WinReleasePS(hps);