diff options
author | patthoyts <patthoyts@users.sourceforge.net> | 2008-11-22 20:05:32 (GMT) |
---|---|---|
committer | patthoyts <patthoyts@users.sourceforge.net> | 2008-11-22 20:05:32 (GMT) |
commit | d018f5251d22906500e7f6b867ba151fdd4f589d (patch) | |
tree | 4c1f685abe81acb723e581ebb1a54635f639a27b /win | |
parent | 08d210474dcf15c239160ca885bd7799ac618787 (diff) | |
download | tk-d018f5251d22906500e7f6b867ba151fdd4f589d.zip tk-d018f5251d22906500e7f6b867ba151fdd4f589d.tar.gz tk-d018f5251d22906500e7f6b867ba151fdd4f589d.tar.bz2 |
Fixed up complaints from MSVC engendered by the last commit. In particular replaced round() which is a C99 function.
Diffstat (limited to 'win')
-rw-r--r-- | win/tkWinDraw.c | 3 | ||||
-rw-r--r-- | win/tkWinFont.c | 14 |
2 files changed, 8 insertions, 9 deletions
diff --git a/win/tkWinDraw.c b/win/tkWinDraw.c index 15821f3..9d1a7cd 100644 --- a/win/tkWinDraw.c +++ b/win/tkWinDraw.c @@ -10,7 +10,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tkWinDraw.c,v 1.22 2008/11/08 18:44:40 dkf Exp $ + * RCS: @(#) $Id: tkWinDraw.c,v 1.23 2008/11/22 20:05:32 patthoyts Exp $ */ #include "tkWinInt.h" @@ -19,7 +19,6 @@ * These macros convert between X's bizarre angle units to radians. */ -#define PI 3.14159265358979 #define XAngleToRadians(a) ((double)(a) / 64 * PI / 180); /* diff --git a/win/tkWinFont.c b/win/tkWinFont.c index 264acc2..9fa4963 100644 --- a/win/tkWinFont.c +++ b/win/tkWinFont.c @@ -11,7 +11,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tkWinFont.c,v 1.44 2008/11/22 18:08:51 dkf Exp $ + * RCS: @(#) $Id: tkWinFont.c,v 1.45 2008/11/22 20:05:32 patthoyts Exp $ */ #include "tkWinInt.h" @@ -1298,12 +1298,12 @@ TkpDrawAngledChars( */ PatBlt(dcMem, 0, 0, size.cx, size.cy, BLACKNESS); - MultiFontTextOut(dc, fontPtr, source, numBytes, x, y, angle); - BitBlt(dc, x, y - tm.tmAscent, size.cx, size.cy, dcMem, + MultiFontTextOut(dc, fontPtr, source, numBytes, (int)x, (int)y, angle); + BitBlt(dc, (int)x, (int)y - tm.tmAscent, size.cx, size.cy, dcMem, 0, 0, 0xEA02E9); PatBlt(dcMem, 0, 0, size.cx, size.cy, WHITENESS); - MultiFontTextOut(dc, fontPtr, source, numBytes, x, y, angle); - BitBlt(dc, x, y - tm.tmAscent, size.cx, size.cy, dcMem, + MultiFontTextOut(dc, fontPtr, source, numBytes, (int)x, (int)y, angle); + BitBlt(dc, (int)x, (int)y - tm.tmAscent, size.cx, size.cy, dcMem, 0, 0, 0x8A0E06); /* @@ -1319,7 +1319,7 @@ TkpDrawAngledChars( SetTextAlign(dc, TA_LEFT | TA_BASELINE); SetTextColor(dc, gc->foreground); SetBkMode(dc, TRANSPARENT); - MultiFontTextOut(dc, fontPtr, source, numBytes, x, y, angle); + MultiFontTextOut(dc, fontPtr, source, numBytes, (int)x, (int)y, angle); } else { HBITMAP oldBitmap, bitmap; HDC dcMem; @@ -1345,7 +1345,7 @@ TkpDrawAngledChars( MultiFontTextOut(dcMem, fontPtr, source, numBytes, 0, tm.tmAscent, angle); - BitBlt(dc, x, y - tm.tmAscent, size.cx, size.cy, dcMem, + BitBlt(dc, (int)x, (int)y - tm.tmAscent, size.cx, size.cy, dcMem, 0, 0, (DWORD) tkpWinBltModes[gc->function]); /* |