Import Tk 8.6.10

This commit is contained in:
Steve Dower
2020-09-24 22:55:34 +01:00
parent 5ba5cbc9af
commit 42c69189d9
365 changed files with 24323 additions and 12832 deletions

View File

@@ -13,6 +13,7 @@
#include "tkInt.h"
#include "tkCanvas.h"
#include "default.h"
/*
* The structure below defines the record for each line item.
@@ -175,7 +176,7 @@ static const Tk_ConfigSpec configSpecs[] = {
{TK_CONFIG_CAP_STYLE, "-capstyle", NULL, NULL,
"butt", Tk_Offset(LineItem, capStyle), TK_CONFIG_DONT_SET_DEFAULT, NULL},
{TK_CONFIG_COLOR, "-fill", NULL, NULL,
"black", Tk_Offset(LineItem, outline.color), TK_CONFIG_NULL_OK, NULL},
DEF_CANVITEM_OUTLINE, Tk_Offset(LineItem, outline.color), TK_CONFIG_NULL_OK, NULL},
{TK_CONFIG_CUSTOM, "-dash", NULL, NULL,
NULL, Tk_Offset(LineItem, outline.dash),
TK_CONFIG_NULL_OK, &dashOption},
@@ -296,7 +297,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;
@@ -521,12 +522,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;
@@ -611,7 +612,7 @@ DeleteLine(
if (linePtr->coordPtr != NULL) {
ckfree(linePtr->coordPtr);
}
if (linePtr->arrowGC != None) {
if (linePtr->arrowGC != NULL) {
Tk_FreeGC(display, linePtr->arrowGC);
}
if (linePtr->firstArrowPtr != NULL) {
@@ -840,7 +841,7 @@ DisplayLine(
int numPoints;
Tk_State state = itemPtr->state;
if ((!linePtr->numPoints) || (linePtr->outline.gc == None)) {
if (!linePtr->numPoints || (linePtr->outline.gc == NULL)) {
return;
}