diff options
author | jan.nijtmans <jan.nijtmans@noemail.net> | 2012-06-07 08:08:30 (GMT) |
---|---|---|
committer | jan.nijtmans <jan.nijtmans@noemail.net> | 2012-06-07 08:08:30 (GMT) |
commit | 53a8fa286f84fe054bef1be6a00c8adb2ce2d51d (patch) | |
tree | 7981088cb257579d4bcf74b7735557ca697528c7 /win/tkWinDraw.c | |
parent | 9b332879453a68b48ddb87b8ccbcbc20f11cf40c (diff) | |
parent | d716832a92c308bee9ab5f666a78822784814948 (diff) | |
download | tk-53a8fa286f84fe054bef1be6a00c8adb2ce2d51d.zip tk-53a8fa286f84fe054bef1be6a00c8adb2ce2d51d.tar.gz tk-53a8fa286f84fe054bef1be6a00c8adb2ce2d51d.tar.bz2 |
Change XChangeWindowAttributes signature and many others to match Xorg, needed for Cygwin
FossilOrigin-Name: 3bd080b93c0124d1449dd6cf4b306b4c2619a514
Diffstat (limited to 'win/tkWinDraw.c')
-rw-r--r-- | win/tkWinDraw.c | 31 |
1 files changed, 18 insertions, 13 deletions
diff --git a/win/tkWinDraw.c b/win/tkWinDraw.c index 388fd14..1897bc8 100644 --- a/win/tkWinDraw.c +++ b/win/tkWinDraw.c @@ -116,7 +116,7 @@ static Tcl_ThreadDataKey dataKey; static POINT * ConvertPoints(XPoint *points, int npoints, int mode, RECT *bbox); -static void DrawOrFillArc(Display *display, Drawable d, GC gc, +static int DrawOrFillArc(Display *display, Drawable d, GC gc, int x, int y, unsigned int width, unsigned int height, int start, int extent, int fill); @@ -297,7 +297,7 @@ ConvertPoints( *---------------------------------------------------------------------- */ -void +int XCopyArea( Display *display, Drawable src, @@ -333,6 +333,7 @@ XCopyArea( TkWinReleaseDrawableDC(dest, destDC, &destState); } TkWinReleaseDrawableDC(src, srcDC, &srcState); + return Success; } /* @@ -353,7 +354,7 @@ XCopyArea( *---------------------------------------------------------------------- */ -void +int XCopyPlane( Display *display, Drawable src, @@ -480,6 +481,7 @@ XCopyPlane( TkWinReleaseDrawableDC(dest, destDC, &destState); } TkWinReleaseDrawableDC(src, srcDC, &srcState); + return Success; } /* @@ -911,7 +913,7 @@ XDrawLines( *---------------------------------------------------------------------- */ -void +int XFillPolygon( Display *display, Drawable d, @@ -926,7 +928,7 @@ XFillPolygon( HDC dc; if (d == None) { - return; + return BadDrawable; } dc = TkWinGetDrawableDC(display, d, &state); @@ -935,6 +937,7 @@ XFillPolygon( RenderObject(dc, gc, points, npoints, mode, pen, Polygon); TkWinReleaseDrawableDC(d, dc, &state); + return Success; } /* @@ -953,7 +956,7 @@ XFillPolygon( *---------------------------------------------------------------------- */ -void +int XDrawRectangle( Display *display, Drawable d, @@ -967,7 +970,7 @@ XDrawRectangle( HDC dc; if (d == None) { - return; + return BadDrawable; } dc = TkWinGetDrawableDC(display, d, &state); @@ -983,6 +986,7 @@ XDrawRectangle( DeleteObject(SelectObject(dc, oldPen)); SelectObject(dc, oldBrush); TkWinReleaseDrawableDC(d, dc, &state); + return Success; } /* @@ -1001,7 +1005,7 @@ XDrawRectangle( *---------------------------------------------------------------------- */ -void +int XDrawArc( Display *display, Drawable d, @@ -1012,7 +1016,7 @@ XDrawArc( { display->request++; - DrawOrFillArc(display, d, gc, x, y, width, height, start, extent, 0); + return DrawOrFillArc(display, d, gc, x, y, width, height, start, extent, 0); } /* @@ -1031,7 +1035,7 @@ XDrawArc( *---------------------------------------------------------------------- */ -void +int XFillArc( Display *display, Drawable d, @@ -1042,7 +1046,7 @@ XFillArc( { display->request++; - DrawOrFillArc(display, d, gc, x, y, width, height, start, extent, 1); + return DrawOrFillArc(display, d, gc, x, y, width, height, start, extent, 1); } /* @@ -1062,7 +1066,7 @@ XFillArc( *---------------------------------------------------------------------- */ -static void +static int DrawOrFillArc( Display *display, Drawable d, @@ -1082,7 +1086,7 @@ DrawOrFillArc( double radian_start, radian_end, xr, yr; if (d == None) { - return; + return BadDrawable; } dc = TkWinGetDrawableDC(display, d, &state); @@ -1155,6 +1159,7 @@ DrawOrFillArc( } DeleteObject(SelectObject(dc, oldPen)); TkWinReleaseDrawableDC(d, dc, &state); + return Success; } /* |