diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2019-01-08 08:31:34 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2019-01-08 08:31:34 (GMT) |
commit | 1cf82956754b0b42ef212635195b5c29fc93a0fc (patch) | |
tree | b6bf6eaff55be5c6fd20363aea6473c6bfbd76ad /generic/tkCanvLine.c | |
parent | 726546cf2742672ce6de89b0500b3e750c6fe3b7 (diff) | |
parent | d2747a371058fa4128dbd7896fe040f0b3ee6be7 (diff) | |
download | tk-1cf82956754b0b42ef212635195b5c29fc93a0fc.zip tk-1cf82956754b0b42ef212635195b5c29fc93a0fc.tar.gz tk-1cf82956754b0b42ef212635195b5c29fc93a0fc.tar.bz2 |
Fix [9e31fd944934e269121fa78ff56b7b86f33e6db6|9e31fd9449]: X11/X.h and Windows.h have conflicting symbols.
*** POTENTIAL INCOMPATIBILITY *** on Windows only: gcc/clang/MSVC will generate new warnings in extensions when the "None" symbol is used incorrectly.
Those warnings are all fixed in the core, that's what most of this commit is doing.
Diffstat (limited to 'generic/tkCanvLine.c')
-rw-r--r-- | generic/tkCanvLine.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/generic/tkCanvLine.c b/generic/tkCanvLine.c index cce3460..0294aa8 100644 --- a/generic/tkCanvLine.c +++ b/generic/tkCanvLine.c @@ -303,7 +303,7 @@ CreateLine( linePtr->coordPtr = NULL; linePtr->capStyle = CapButt; linePtr->joinStyle = JoinRound; - linePtr->arrowGC = None; + linePtr->arrowGC = NULL; linePtr->arrow = ARROWS_NONE; linePtr->arrowShapeA = (float)8.0; linePtr->arrowShapeB = (float)10.0; @@ -531,12 +531,12 @@ ConfigureLine( #endif arrowGC = Tk_GetGC(tkwin, mask, &gcValues); } else { - newGC = arrowGC = None; + newGC = arrowGC = NULL; } - if (linePtr->outline.gc != None) { + if (linePtr->outline.gc != NULL) { Tk_FreeGC(Tk_Display(tkwin), linePtr->outline.gc); } - if (linePtr->arrowGC != None) { + if (linePtr->arrowGC != NULL) { Tk_FreeGC(Tk_Display(tkwin), linePtr->arrowGC); } linePtr->outline.gc = newGC; @@ -621,7 +621,7 @@ DeleteLine( if (linePtr->coordPtr != NULL) { ckfree((char *) linePtr->coordPtr); } - if (linePtr->arrowGC != None) { + if (linePtr->arrowGC != NULL) { Tk_FreeGC(display, linePtr->arrowGC); } if (linePtr->firstArrowPtr != NULL) { @@ -846,7 +846,7 @@ DisplayLine( int numPoints; Tk_State state = itemPtr->state; - if ((!linePtr->numPoints)||(linePtr->outline.gc==None)) { + if (!linePtr->numPoints || (linePtr->outline.gc == NULL)) { return; } @@ -2251,7 +2251,7 @@ LineToPostscript( * being created. */ { LineItem *linePtr = (LineItem *) itemPtr; - char buffer[64 + TCL_INTEGER_SPACE]; + char buffer[64 + 4*TCL_INTEGER_SPACE]; char *style; double width; |