diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2023-11-30 11:35:13 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2023-11-30 11:35:13 (GMT) |
commit | a0517e3492a1daa156cc249ee91c76740133cd4e (patch) | |
tree | 4944c0eabf279deb8a9cc35f703c60c312334738 /generic | |
parent | 2b3b6f6334373b0e5eec61731bf83e629235d3ed (diff) | |
parent | 5df223b1771334dc89bf52818f093a795506dfe2 (diff) | |
download | tk-a0517e3492a1daa156cc249ee91c76740133cd4e.zip tk-a0517e3492a1daa156cc249ee91c76740133cd4e.tar.gz tk-a0517e3492a1daa156cc249ee91c76740133cd4e.tar.bz2 |
Merge 9.0. More progress
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tk.decls | 8 | ||||
-rw-r--r-- | generic/tk.h | 10 | ||||
-rw-r--r-- | generic/tkCanvArc.c | 4 | ||||
-rw-r--r-- | generic/tkCanvBmap.c | 4 | ||||
-rw-r--r-- | generic/tkCanvImg.c | 4 | ||||
-rw-r--r-- | generic/tkCanvLine.c | 4 | ||||
-rw-r--r-- | generic/tkCanvPoly.c | 4 | ||||
-rw-r--r-- | generic/tkCanvPs.c | 4 | ||||
-rw-r--r-- | generic/tkCanvText.c | 4 | ||||
-rw-r--r-- | generic/tkCanvWind.c | 4 | ||||
-rw-r--r-- | generic/tkCanvas.c | 141 | ||||
-rw-r--r-- | generic/tkConsole.c | 2 | ||||
-rw-r--r-- | generic/tkDecls.h | 28 | ||||
-rw-r--r-- | generic/tkIcu.c | 2 | ||||
-rw-r--r-- | generic/tkImgBmap.c | 10 | ||||
-rw-r--r-- | generic/tkImgPNG.c | 2 | ||||
-rw-r--r-- | generic/tkImgPhoto.c | 10 | ||||
-rw-r--r-- | generic/tkInt.decls | 8 | ||||
-rw-r--r-- | generic/tkIntPlatDecls.h | 12 | ||||
-rw-r--r-- | generic/tkMain.c | 2 | ||||
-rw-r--r-- | generic/tkOldConfig.c | 40 | ||||
-rw-r--r-- | generic/tkRectOval.c | 6 | ||||
-rw-r--r-- | generic/tkScrollbar.c | 10 | ||||
-rw-r--r-- | generic/tkStubInit.c | 4 | ||||
-rw-r--r-- | generic/tkTest.c | 2 | ||||
-rw-r--r-- | generic/tkText.c | 25 | ||||
-rw-r--r-- | generic/tkWindow.c | 2 |
27 files changed, 107 insertions, 249 deletions
diff --git a/generic/tk.decls b/generic/tk.decls index e6c534f..ae693d3 100644 --- a/generic/tk.decls +++ b/generic/tk.decls @@ -136,17 +136,17 @@ declare 26 { declare 27 { int Tk_ConfigureInfo(Tcl_Interp *interp, Tk_Window tkwin, const Tk_ConfigSpec *specs, - char *widgRec, const char *argvName, int flags) + void *widgRec, const char *argvName, int flags) } declare 28 { int Tk_ConfigureValue(Tcl_Interp *interp, Tk_Window tkwin, const Tk_ConfigSpec *specs, - char *widgRec, const char *argvName, int flags) + void *widgRec, const char *argvName, int flags) } declare 29 { int Tk_ConfigureWidget(Tcl_Interp *interp, Tk_Window tkwin, const Tk_ConfigSpec *specs, - Tcl_Size argc, const char **argv, char *widgRec, + Tcl_Size objc, Tcl_Obj *const *objv, void *widgRec, int flags) } declare 30 { @@ -318,7 +318,7 @@ declare 73 { } declare 74 { void Tk_FreeOptions(const Tk_ConfigSpec *specs, - char *widgRec, Display *display, int needFlags) + void *widgRec, Display *display, int needFlags) } declare 75 { void Tk_FreePixmap(Display *display, Pixmap pixmap) diff --git a/generic/tk.h b/generic/tk.h index 52e0e8a..4f4d157 100644 --- a/generic/tk.h +++ b/generic/tk.h @@ -1067,9 +1067,7 @@ typedef struct Tk_ItemType { * type. */ Tk_ItemDisplayProc *displayProc; /* Procedure to display items of this type. */ - int alwaysRedraw; /* Non-zero means displayProc should be called - * even when the item has been moved - * off-screen. */ + int flags; /* Combination of TK_ALWAYS_REDRAW/TK_MOVABLE_POINTS */ Tk_ItemPointProc *pointProc;/* Computes distance from item to a given * point. */ Tk_ItemAreaProc *areaProc; /* Computes whether item is inside, outside, @@ -1106,11 +1104,11 @@ typedef struct Tk_ItemType { } Tk_ItemType; /* - * Flag (used in the alwaysRedraw field) to say whether an item supports - * point-level manipulation like the line and polygon items. + * Possible flags for 'flags' field. */ -#define TK_MOVABLE_POINTS 2 +#define TK_ALWAYS_REDRAW 1 /* item should be redrawn always*/ +#define TK_MOVABLE_POINTS 2 /* item supports point-level manipulation */ #endif /* __NO_OLD_CONFIG */ diff --git a/generic/tkCanvArc.c b/generic/tkCanvArc.c index a730eb9..a7bcfb3 100644 --- a/generic/tkCanvArc.c +++ b/generic/tkCanvArc.c @@ -234,7 +234,7 @@ Tk_ItemType tkArcType = { ArcCoords, /* coordProc */ DeleteArc, /* deleteProc */ DisplayArc, /* displayProc */ - TK_CONFIG_OBJS, /* flags */ + 0, /* flags */ ArcToPoint, /* pointProc */ ArcToArea, /* areaProc */ ArcToPostscript, /* postscriptProc */ @@ -452,7 +452,7 @@ ConfigureArc( tkwin = Tk_CanvasTkwin(canvas); if (TCL_OK != Tk_ConfigureWidget(interp, tkwin, configSpecs, objc, - (const char **) objv, (char *) arcPtr, flags|TK_CONFIG_OBJS)) { + objv, arcPtr, flags)) { return TCL_ERROR; } diff --git a/generic/tkCanvBmap.c b/generic/tkCanvBmap.c index 49e73cb..f2f2ca5 100644 --- a/generic/tkCanvBmap.c +++ b/generic/tkCanvBmap.c @@ -128,7 +128,7 @@ Tk_ItemType tkBitmapType = { BitmapCoords, /* coordProc */ DeleteBitmap, /* deleteProc */ DisplayBitmap, /* displayProc */ - TK_CONFIG_OBJS, /* flags */ + 0, /* flags */ BitmapToPoint, /* pointProc */ BitmapToArea, /* areaProc */ BitmapToPostscript, /* postscriptProc */ @@ -324,7 +324,7 @@ ConfigureBitmap( tkwin = Tk_CanvasTkwin(canvas); if (TCL_OK != Tk_ConfigureWidget(interp, tkwin, configSpecs, objc, - (const char **) objv, (char *) bmapPtr, flags|TK_CONFIG_OBJS)) { + objv, bmapPtr, flags)) { return TCL_ERROR; } diff --git a/generic/tkCanvImg.c b/generic/tkCanvImg.c index 0d45dcb..9a105d9 100644 --- a/generic/tkCanvImg.c +++ b/generic/tkCanvImg.c @@ -116,7 +116,7 @@ Tk_ItemType tkImageType = { ImageCoords, /* coordProc */ DeleteImage, /* deleteProc */ DisplayImage, /* displayProc */ - TK_CONFIG_OBJS, /* flags */ + 0, /* flags */ ImageToPoint, /* pointProc */ ImageToArea, /* areaProc */ ImageToPostscript, /* postscriptProc */ @@ -302,7 +302,7 @@ ConfigureImage( tkwin = Tk_CanvasTkwin(canvas); if (TCL_OK != Tk_ConfigureWidget(interp, tkwin, configSpecs, objc, - (const char **) objv, (char *) imgPtr, flags|TK_CONFIG_OBJS)) { + objv, imgPtr, flags)) { return TCL_ERROR; } diff --git a/generic/tkCanvLine.c b/generic/tkCanvLine.c index 8f2595f..861c8ba 100644 --- a/generic/tkCanvLine.c +++ b/generic/tkCanvLine.c @@ -234,7 +234,7 @@ Tk_ItemType tkLineType = { LineCoords, /* coordProc */ DeleteLine, /* deleteProc */ DisplayLine, /* displayProc */ - TK_CONFIG_OBJS | TK_MOVABLE_POINTS, /* flags */ + TK_MOVABLE_POINTS, /* flags */ LineToPoint, /* pointProc */ LineToArea, /* areaProc */ LineToPostscript, /* postscriptProc */ @@ -486,7 +486,7 @@ ConfigureLine( tkwin = Tk_CanvasTkwin(canvas); if (TCL_OK != Tk_ConfigureWidget(interp, tkwin, configSpecs, objc, - (const char **) objv, (char *) linePtr, flags|TK_CONFIG_OBJS)) { + objv, linePtr, flags)) { return TCL_ERROR; } diff --git a/generic/tkCanvPoly.c b/generic/tkCanvPoly.c index 3d93afa..f0d6031 100644 --- a/generic/tkCanvPoly.c +++ b/generic/tkCanvPoly.c @@ -199,7 +199,7 @@ Tk_ItemType tkPolygonType = { PolygonCoords, /* coordProc */ DeletePolygon, /* deleteProc */ DisplayPolygon, /* displayProc */ - TK_CONFIG_OBJS | TK_MOVABLE_POINTS, /* flags */ + TK_MOVABLE_POINTS, /* flags */ PolygonToPoint, /* pointProc */ PolygonToArea, /* areaProc */ PolygonToPostscript, /* postscriptProc */ @@ -446,7 +446,7 @@ ConfigurePolygon( tkwin = Tk_CanvasTkwin(canvas); if (TCL_OK != Tk_ConfigureWidget(interp, tkwin, configSpecs, objc, - (const char **) objv, (char *) polyPtr, flags|TK_CONFIG_OBJS)) { + objv, polyPtr, flags)) { return TCL_ERROR; } diff --git a/generic/tkCanvPs.c b/generic/tkCanvPs.c index d9759d7..f5b9a8b 100644 --- a/generic/tkCanvPs.c +++ b/generic/tkCanvPs.c @@ -236,8 +236,8 @@ TkCanvPostscriptObjCmd( psInfo.prolog = 1; psInfo.tkwin = tkwin; Tcl_InitHashTable(&psInfo.fontTable, TCL_STRING_KEYS); - result = Tk_ConfigureWidget(interp, tkwin, configSpecs, objc-2, (const char **)objv+2, - (char *) &psInfo, TK_CONFIG_ARGV_ONLY|TK_CONFIG_OBJS); + result = Tk_ConfigureWidget(interp, tkwin, configSpecs, objc-2, objv+2, + &psInfo, TK_CONFIG_ARGV_ONLY); if (result != TCL_OK) { goto cleanup; } diff --git a/generic/tkCanvText.c b/generic/tkCanvText.c index 0203343..e57e0f1 100644 --- a/generic/tkCanvText.c +++ b/generic/tkCanvText.c @@ -272,7 +272,7 @@ Tk_ItemType tkTextType = { TextCoords, /* coordProc */ DeleteText, /* deleteProc */ DisplayCanvText, /* displayProc */ - TK_CONFIG_OBJS, /* flags */ + 0, /* flags */ TextToPoint, /* pointProc */ TextToArea, /* areaProc */ TextToPostscript, /* postscriptProc */ @@ -494,7 +494,7 @@ ConfigureText( tkwin = Tk_CanvasTkwin(canvas); if (TCL_OK != Tk_ConfigureWidget(interp, tkwin, configSpecs, objc, - (const char **) objv, (char *) textPtr, flags|TK_CONFIG_OBJS)) { + objv, textPtr, flags)) { return TCL_ERROR; } diff --git a/generic/tkCanvWind.c b/generic/tkCanvWind.c index e614b92..050ba3e 100644 --- a/generic/tkCanvWind.c +++ b/generic/tkCanvWind.c @@ -120,7 +120,7 @@ Tk_ItemType tkWindowType = { WinItemCoords, /* coordProc */ DeleteWinItem, /* deleteProc */ DisplayWinItem, /* displayProc */ - 1|TK_CONFIG_OBJS, /* flags */ + TK_ALWAYS_REDRAW, /* flags */ WinItemToPoint, /* pointProc */ WinItemToArea, /* areaProc */ WinItemToPostscript, /* postscriptProc */ @@ -316,7 +316,7 @@ ConfigureWinItem( oldWindow = winItemPtr->tkwin; canvasTkwin = Tk_CanvasTkwin(canvas); if (TCL_OK != Tk_ConfigureWidget(interp, canvasTkwin, configSpecs, objc, - (const char **) objv, (char *) winItemPtr, flags|TK_CONFIG_OBJS)) { + objv, winItemPtr, flags)) { return TCL_ERROR; } diff --git a/generic/tkCanvas.c b/generic/tkCanvas.c index 2b5568d..26941b0 100644 --- a/generic/tkCanvas.c +++ b/generic/tkCanvas.c @@ -260,9 +260,6 @@ static int FindItems(Tcl_Interp *interp, TkCanvas *canvasPtr, static int FindArea(Tcl_Interp *interp, TkCanvas *canvasPtr, Tcl_Obj *const *objv, Tk_Uid uid, int enclosed); static double GridAlign(double coord, double spacing); -#if !defined(TK_NO_DEPRECATED) && (TK_MAJOR_VERSION < 9) -static const char** TkGetStringsFromObjs(Tcl_Size objc, Tcl_Obj *const *objv); -#endif static void InitCanvas(void); static void PickCurrentItem(TkCanvas *canvasPtr, XEvent *eventPtr); static Tcl_Obj * ScrollFractions(int screen1, @@ -328,7 +325,7 @@ static inline int AlwaysRedraw( Tk_Item *itemPtr) { - return itemPtr->typePtr->alwaysRedraw & 1; + return itemPtr->typePtr->flags & TK_ALWAYS_REDRAW; } static inline int @@ -339,25 +336,9 @@ ItemConfigure( Tcl_Obj *const objv[]) { Tcl_Interp *interp = canvasPtr->interp; - int result; - if (itemPtr->typePtr->alwaysRedraw & TK_CONFIG_OBJS) { - result = itemPtr->typePtr->configProc(interp, (Tk_Canvas) canvasPtr, - itemPtr, objc, objv, TK_CONFIG_ARGV_ONLY); - } else { -#if defined(TK_NO_DEPRECATED) || (TK_MAJOR_VERSION > 8) - Tcl_Panic("Flag TK_CONFIG_OBJS is mandatory"); -#else - const char **args = TkGetStringsFromObjs(objc, objv); - - result = itemPtr->typePtr->configProc(interp, (Tk_Canvas) canvasPtr, - itemPtr, objc, (Tcl_Obj **) args, TK_CONFIG_ARGV_ONLY); - if (args != NULL) { - ckfree(args); - } -#endif - } - return result; + return itemPtr->typePtr->configProc(interp, (Tk_Canvas) canvasPtr, + itemPtr, objc, objv, TK_CONFIG_ARGV_ONLY); } static inline int @@ -367,7 +348,7 @@ ItemConfigInfo( Tcl_Obj *fieldName) { return Tk_ConfigureInfo(canvasPtr->interp, canvasPtr->tkwin, - itemPtr->typePtr->configSpecs, (char *) itemPtr, + itemPtr->typePtr->configSpecs, itemPtr, (fieldName ? Tcl_GetString(fieldName) : NULL), 0); } @@ -378,7 +359,7 @@ ItemConfigValue( Tcl_Obj *fieldName) { return Tk_ConfigureValue(canvasPtr->interp, canvasPtr->tkwin, - itemPtr->typePtr->configSpecs, (char *) itemPtr, + itemPtr->typePtr->configSpecs, itemPtr, Tcl_GetString(fieldName), 0); } @@ -394,21 +375,9 @@ ItemCoords( if (itemPtr->typePtr->coordProc == NULL) { result = TCL_OK; - } else if (itemPtr->typePtr->alwaysRedraw & TK_CONFIG_OBJS) { - result = itemPtr->typePtr->coordProc(interp, (Tk_Canvas) canvasPtr, - itemPtr, objc, objv); } else { -#if defined(TK_NO_DEPRECATED) || (TK_MAJOR_VERSION > 8) - Tcl_Panic("Flag TK_CONFIG_OBJS is mandatory"); -#else - const char **args = TkGetStringsFromObjs(objc, objv); - result = itemPtr->typePtr->coordProc(interp, (Tk_Canvas) canvasPtr, - itemPtr, objc, (Tcl_Obj **) args); - if (args != NULL) { - ckfree(args); - } -#endif + itemPtr, objc, objv); } return result; } @@ -422,25 +391,9 @@ ItemCreate( Tcl_Obj *const objv[]) { Tcl_Interp *interp = canvasPtr->interp; - int result; - if (itemPtr->typePtr->alwaysRedraw & TK_CONFIG_OBJS) { - result = itemPtr->typePtr->createProc(interp, (Tk_Canvas) canvasPtr, + return itemPtr->typePtr->createProc(interp, (Tk_Canvas) canvasPtr, itemPtr, objc-3, objv+3); - } else { -#if defined(TK_NO_DEPRECATED) || (TK_MAJOR_VERSION > 8) - Tcl_Panic("Flag TK_CONFIG_OBJS is mandatory"); -#else - const char **args = TkGetStringsFromObjs(objc-3, objv+3); - - result = itemPtr->typePtr->createProc(interp, (Tk_Canvas) canvasPtr, - itemPtr, objc-3, (Tcl_Obj **) args); - if (args != NULL) { - ckfree(args); - } -#endif - } - return result; } static inline void @@ -494,18 +447,9 @@ ItemIndex( if (itemPtr->typePtr->indexProc == NULL) { return TCL_OK; - } else if (itemPtr->typePtr->alwaysRedraw & TK_CONFIG_OBJS) { - return itemPtr->typePtr->indexProc(interp, (Tk_Canvas) canvasPtr, - itemPtr, objPtr, indexPtr); - } else { -#if defined(TK_NO_DEPRECATED) - Tcl_AppendResult(interp, "Flag TK_CONFIG_OBJS is mandatory", (void *)NULL); - return TCL_ERROR; -#else - return itemPtr->typePtr->indexProc(interp, (Tk_Canvas) canvasPtr, - itemPtr, (Tcl_Obj *) Tcl_GetString(objPtr), indexPtr); -#endif } + return itemPtr->typePtr->indexProc(interp, (Tk_Canvas) canvasPtr, + itemPtr, objPtr, indexPtr); } static inline void @@ -515,17 +459,8 @@ ItemInsert( int beforeThis, Tcl_Obj *toInsert) { - if (itemPtr->typePtr->alwaysRedraw & TK_CONFIG_OBJS) { - itemPtr->typePtr->insertProc((Tk_Canvas) canvasPtr, itemPtr, - beforeThis, toInsert); - } else { -#if defined(TK_NO_DEPRECATED) || (TK_MAJOR_VERSION > 8) - Tcl_Panic("Flag TK_CONFIG_OBJS is mandatory"); -#else - itemPtr->typePtr->insertProc((Tk_Canvas) canvasPtr, itemPtr, - beforeThis, (Tcl_Obj *) Tcl_GetString(toInsert)); -#endif - } + itemPtr->typePtr->insertProc((Tk_Canvas) canvasPtr, itemPtr, + beforeThis, toInsert); } static inline int @@ -1164,15 +1099,15 @@ CanvasWidgetCmd( goto done; } result = Tk_ConfigureValue(interp, canvasPtr->tkwin, configSpecs, - (char *) canvasPtr, Tcl_GetString(objv[2]), 0); + canvasPtr, Tcl_GetString(objv[2]), 0); break; case CANV_CONFIGURE: if (objc == 2) { result = Tk_ConfigureInfo(interp, canvasPtr->tkwin, configSpecs, - (char *) canvasPtr, NULL, 0); + canvasPtr, NULL, 0); } else if (objc == 3) { result = Tk_ConfigureInfo(interp, canvasPtr->tkwin, configSpecs, - (char *) canvasPtr, Tcl_GetString(objv[2]), 0); + canvasPtr, Tcl_GetString(objv[2]), 0); } else { result = ConfigureCanvas(interp, canvasPtr, objc-2, objv+2, TK_CONFIG_ARGV_ONLY); @@ -1231,7 +1166,7 @@ CanvasWidgetCmd( */ if (itemPtr == NULL || - !(itemPtr->typePtr->alwaysRedraw & TK_MOVABLE_POINTS)) { + !(itemPtr->typePtr->flags & TK_MOVABLE_POINTS)) { continue; } @@ -2286,7 +2221,7 @@ DestroyCanvas( if (canvasPtr->bindingTable != NULL) { Tk_DeleteBindingTable(canvasPtr->bindingTable); } - Tk_FreeOptions(configSpecs, (char *) canvasPtr, canvasPtr->display, 0); + Tk_FreeOptions(configSpecs, canvasPtr, canvasPtr->display, 0); canvasPtr->tkwin = NULL; ckfree(canvasPtr); } @@ -2325,8 +2260,8 @@ ConfigureCanvas( Tk_State old_canvas_state=canvasPtr->canvas_state; if (Tk_ConfigureWidget(interp, canvasPtr->tkwin, configSpecs, - objc, (const char **) objv, (char *) canvasPtr, - flags|TK_CONFIG_OBJS) != TCL_OK) { + objc, objv, canvasPtr, + flags) != TCL_OK) { return TCL_ERROR; } @@ -3361,8 +3296,8 @@ CanvasEventProc( /* * Special hack: if the canvas is unmapped, then must notify all items - * with "alwaysRedraw" set, so that they know that they are no longer - * displayed. + * with flag TK_ALWAYS_REDRAW set, so that they know that they are no + * longer displayed. */ for (itemPtr = canvasPtr->firstItemPtr; itemPtr != NULL; @@ -6091,43 +6026,7 @@ CanvasSetOrigin( canvasPtr->xOrigin + Tk_Width(canvasPtr->tkwin), canvasPtr->yOrigin + Tk_Height(canvasPtr->tkwin)); } - -/* - *---------------------------------------------------------------------- - * - * TkGetStringsFromObjs -- - * - * Results: - * Converts object list into string list. - * - * Side effects: - * Memory is allocated for the objv array, which must be freed using - * ckfree() when no longer needed. - * - *---------------------------------------------------------------------- - */ - -#if !defined(TK_NO_DEPRECATED) && (TK_MAJOR_VERSION < 9) -static const char ** -TkGetStringsFromObjs( - Tcl_Size objc, - Tcl_Obj *const objv[]) -{ - Tcl_Size i; - const char **argv; - if (objc <= 0) { - return NULL; - } - argv = (const char **)ckalloc((objc+1) * sizeof(char *)); - for (i = 0; i < objc; i++) { - argv[i] = Tcl_GetString(objv[i]); - } - argv[objc] = 0; - return argv; -} -#endif - /* *-------------------------------------------------------------- * diff --git a/generic/tkConsole.c b/generic/tkConsole.c index 88aacd4..aa9c476 100644 --- a/generic/tkConsole.c +++ b/generic/tkConsole.c @@ -224,7 +224,7 @@ Tk_InitConsoleChannels( * Ensure that we are getting a compatible version of Tcl. */ - if (Tcl_InitStubs(interp, "8.6-", 0) == NULL) { + if (Tcl_InitStubs(interp, "8.7-", 0) == NULL) { return; } diff --git a/generic/tkDecls.h b/generic/tkDecls.h index 1a72f99..cb39e7b 100644 --- a/generic/tkDecls.h +++ b/generic/tkDecls.h @@ -132,18 +132,18 @@ EXTERN int Tk_ClipboardClear(Tcl_Interp *interp, Tk_Window tkwin); /* 27 */ EXTERN int Tk_ConfigureInfo(Tcl_Interp *interp, Tk_Window tkwin, - const Tk_ConfigSpec *specs, char *widgRec, + const Tk_ConfigSpec *specs, void *widgRec, const char *argvName, int flags); /* 28 */ EXTERN int Tk_ConfigureValue(Tcl_Interp *interp, Tk_Window tkwin, const Tk_ConfigSpec *specs, - char *widgRec, const char *argvName, + void *widgRec, const char *argvName, int flags); /* 29 */ EXTERN int Tk_ConfigureWidget(Tcl_Interp *interp, Tk_Window tkwin, const Tk_ConfigSpec *specs, - Tcl_Size argc, const char **argv, - char *widgRec, int flags); + Tcl_Size objc, Tcl_Obj *const *objv, + void *widgRec, int flags); /* 30 */ EXTERN void Tk_ConfigureWindow(Tk_Window tkwin, unsigned int valueMask, @@ -282,7 +282,7 @@ EXTERN void Tk_FreeGC(Display *display, GC gc); EXTERN void Tk_FreeImage(Tk_Image image); /* 74 */ EXTERN void Tk_FreeOptions(const Tk_ConfigSpec *specs, - char *widgRec, Display *display, + void *widgRec, Display *display, int needFlags); /* 75 */ EXTERN void Tk_FreePixmap(Display *display, Pixmap pixmap); @@ -926,9 +926,9 @@ typedef struct TkStubs { void (*tk_ClearSelection) (Tk_Window tkwin, Atom selection); /* 24 */ int (*tk_ClipboardAppend) (Tcl_Interp *interp, Tk_Window tkwin, Atom target, Atom format, const char *buffer); /* 25 */ int (*tk_ClipboardClear) (Tcl_Interp *interp, Tk_Window tkwin); /* 26 */ - int (*tk_ConfigureInfo) (Tcl_Interp *interp, Tk_Window tkwin, const Tk_ConfigSpec *specs, char *widgRec, const char *argvName, int flags); /* 27 */ - int (*tk_ConfigureValue) (Tcl_Interp *interp, Tk_Window tkwin, const Tk_ConfigSpec *specs, char *widgRec, const char *argvName, int flags); /* 28 */ - int (*tk_ConfigureWidget) (Tcl_Interp *interp, Tk_Window tkwin, const Tk_ConfigSpec *specs, Tcl_Size argc, const char **argv, char *widgRec, int flags); /* 29 */ + int (*tk_ConfigureInfo) (Tcl_Interp *interp, Tk_Window tkwin, const Tk_ConfigSpec *specs, void *widgRec, const char *argvName, int flags); /* 27 */ + int (*tk_ConfigureValue) (Tcl_Interp *interp, Tk_Window tkwin, const Tk_ConfigSpec *specs, void *widgRec, const char *argvName, int flags); /* 28 */ + int (*tk_ConfigureWidget) (Tcl_Interp *interp, Tk_Window tkwin, const Tk_ConfigSpec *specs, Tcl_Size objc, Tcl_Obj *const *objv, void *widgRec, int flags); /* 29 */ void (*tk_ConfigureWindow) (Tk_Window tkwin, unsigned int valueMask, XWindowChanges *valuePtr); /* 30 */ Tk_TextLayout (*tk_ComputeTextLayout) (Tk_Font font, const char *str, Tcl_Size numChars, int wrapLength, Tk_Justify justify, int flags, int *widthPtr, int *heightPtr); /* 31 */ Tk_Window (*tk_CoordsToWindow) (int rootX, int rootY, Tk_Window tkwin); /* 32 */ @@ -973,7 +973,7 @@ typedef struct TkStubs { void (*tk_FreeFont) (Tk_Font f); /* 71 */ void (*tk_FreeGC) (Display *display, GC gc); /* 72 */ void (*tk_FreeImage) (Tk_Image image); /* 73 */ - void (*tk_FreeOptions) (const Tk_ConfigSpec *specs, char *widgRec, Display *display, int needFlags); /* 74 */ + void (*tk_FreeOptions) (const Tk_ConfigSpec *specs, void *widgRec, Display *display, int needFlags); /* 74 */ void (*tk_FreePixmap) (Display *display, Pixmap pixmap); /* 75 */ void (*tk_FreeTextLayout) (Tk_TextLayout textLayout); /* 76 */ void (*reserved77)(void); @@ -1791,6 +1791,16 @@ EXTERN int Tk_Init(Tcl_Interp *interp); EXTERN int Tk_SafeInit(Tcl_Interp *interp); EXTERN int Tk_CreateConsoleWindow(Tcl_Interp *interp); +#if TK_MAJOR_VERSION < 9 +/* Restore 8.x signature of Tk_ConfigureWidget, but panic if TK_CONFIG_OBJS flag is not set */ +#undef Tk_ConfigureWidget +#define Tk_ConfigureWidget(interp, tkwin, specs, argc, argv, widgRec, flags) \ + ((int (*)(Tcl_Interp *, Tk_Window, const Tk_ConfigSpec *, \ + int, const char **, char *, int))(void *)(tkStubsPtr->tk_ConfigureWidget)) \ + (((flags & TK_CONFIG_OBJS) ? interp : (Tcl_Panic("Flag TK_CONFIG_OBJS is mandatory in Tk_ConfigureWidget"), \ + NULL)), tkwin, specs, argc, argv, widgRec, flags) +#endif + #undef TCL_STORAGE_CLASS #define TCL_STORAGE_CLASS DLLIMPORT diff --git a/generic/tkIcu.c b/generic/tkIcu.c index 237daf8..3ccb7f6 100644 --- a/generic/tkIcu.c +++ b/generic/tkIcu.c @@ -155,7 +155,7 @@ startEndOfCmd( Tcl_DStringFree(&ds); if (idx != TCL_INDEX_NONE) { if (idx > 0 && len != ulen) { - /* The string contains codepoints > \uFFFF. Determine UTF-16 index */ + /* The string contains codepoints > \uFFFF. Determine UTF-32 index */ Tcl_Size newIdx = 1; for (Tcl_Size i = 1; i < idx; i++) { if (((ustr[i-1]&0xFFC0) != 0xD800) || ((ustr[i]&0xFFC0) != 0xDC00)) newIdx++; diff --git a/generic/tkImgBmap.c b/generic/tkImgBmap.c index 9344777..2fad264 100644 --- a/generic/tkImgBmap.c +++ b/generic/tkImgBmap.c @@ -240,7 +240,7 @@ ImgBmapConfigureModel( int maskWidth, maskHeight, dummy1, dummy2; if (Tk_ConfigureWidget(modelPtr->interp, Tk_MainWindow(modelPtr->interp), - configSpecs, objc, (const char **) objv, (char *) modelPtr, flags|TK_CONFIG_OBJS) != TCL_OK) { + configSpecs, objc, objv, modelPtr, flags) != TCL_OK) { return TCL_ERROR; } @@ -768,14 +768,14 @@ ImgBmapCmd( return TCL_ERROR; } return Tk_ConfigureValue(interp, Tk_MainWindow(interp), configSpecs, - (char *) modelPtr, Tcl_GetString(objv[2]), 0); + modelPtr, Tcl_GetString(objv[2]), 0); case 1: /* configure */ if (objc == 2) { return Tk_ConfigureInfo(interp, Tk_MainWindow(interp), - configSpecs, (char *) modelPtr, NULL, 0); + configSpecs, modelPtr, NULL, 0); } else if (objc == 3) { return Tk_ConfigureInfo(interp, Tk_MainWindow(interp), - configSpecs, (char *) modelPtr, + configSpecs, modelPtr, Tcl_GetString(objv[2]), 0); } else { return ImgBmapConfigureModel(modelPtr, objc-2, objv+2, @@ -1017,7 +1017,7 @@ ImgBmapDelete( if (modelPtr->maskData != NULL) { ckfree(modelPtr->maskData); } - Tk_FreeOptions(configSpecs, (char *) modelPtr, NULL, 0); + Tk_FreeOptions(configSpecs, modelPtr, NULL, 0); ckfree(modelPtr); } diff --git a/generic/tkImgPNG.c b/generic/tkImgPNG.c index 499ffed..5eb85a7 100644 --- a/generic/tkImgPNG.c +++ b/generic/tkImgPNG.c @@ -481,7 +481,7 @@ ReadBase64( 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, 0x83, - 0x83, 0x83 + 0x83, 0x83, 0x83 }; /* diff --git a/generic/tkImgPhoto.c b/generic/tkImgPhoto.c index 79b1363..4a7d4ed 100644 --- a/generic/tkImgPhoto.c +++ b/generic/tkImgPhoto.c @@ -485,7 +485,7 @@ ImgPhotoCmd( } } else { Tk_ConfigureValue(interp, Tk_MainWindow(interp), configSpecs, - (char *) modelPtr, Tcl_GetString(objv[2]), 0); + modelPtr, Tcl_GetString(objv[2]), 0); } return TCL_OK; } @@ -499,7 +499,7 @@ ImgPhotoCmd( Tcl_Obj *obj, *subobj; result = Tk_ConfigureInfo(interp, Tk_MainWindow(interp), - configSpecs, (char *) modelPtr, NULL, 0); + configSpecs, modelPtr, NULL, 0); if (result != TCL_OK) { return result; } @@ -575,7 +575,7 @@ ImgPhotoCmd( return TCL_OK; } else { return Tk_ConfigureInfo(interp, Tk_MainWindow(interp), - configSpecs, (char *) modelPtr, arg, 0); + configSpecs, modelPtr, arg, 0); } } else { return ImgPhotoConfigureModel(interp, modelPtr, objc-2, objv+2, @@ -1973,7 +1973,7 @@ ImgPhotoConfigureModel( */ if (Tk_ConfigureWidget(interp, Tk_MainWindow(interp), configSpecs, - objc, (const char **)objv, (char *) modelPtr, flags|TK_CONFIG_OBJS) != TCL_OK) { + objc, objv, modelPtr, flags) != TCL_OK) { goto errorExit; } @@ -2388,7 +2388,7 @@ ImgPhotoDelete( if (modelPtr->metadata != NULL) { Tcl_DecrRefCount(modelPtr->metadata); } - Tk_FreeOptions(configSpecs, (char *) modelPtr, NULL, 0); + Tk_FreeOptions(configSpecs, modelPtr, NULL, 0); ckfree(modelPtr); } diff --git a/generic/tkInt.decls b/generic/tkInt.decls index e16a72b..aaa32c6 100644 --- a/generic/tkInt.decls +++ b/generic/tkInt.decls @@ -951,10 +951,10 @@ declare 51 aqua { declare 52 aqua { void TkMacOSXSetDrawingEnabled(TkWindow *winPtr, int flag) } -# For Canvas3d, requested by Sean Woods -declare 54 aqua { - void *TkMacOSXDrawable(Drawable drawable) -} +# Made public as Tk_MacOSXGetNSWindowForDrawable +#declare 54 aqua { +# void *TkMacOSXDrawable(Drawable drawable) +#} ############################################################################## diff --git a/generic/tkIntPlatDecls.h b/generic/tkIntPlatDecls.h index e470575..a684b21 100644 --- a/generic/tkIntPlatDecls.h +++ b/generic/tkIntPlatDecls.h @@ -248,9 +248,6 @@ EXTERN int TkGenerateButtonEvent(int x, int y, Window window, EXTERN void TkGenWMDestroyEvent(Tk_Window tkwin); /* 52 */ EXTERN void TkMacOSXSetDrawingEnabled(TkWindow *winPtr, int flag); -/* Slot 53 is reserved */ -/* 54 */ -EXTERN void * TkMacOSXDrawable(Drawable drawable); #endif /* AQUA */ #if !(defined(_WIN32) || defined(__CYGWIN__) || defined(MAC_OSX_TK)) /* X11 */ /* 0 */ @@ -424,8 +421,6 @@ typedef struct TkIntPlatStubs { int (*tkGenerateButtonEvent) (int x, int y, Window window, unsigned int state); /* 50 */ void (*tkGenWMDestroyEvent) (Tk_Window tkwin); /* 51 */ void (*tkMacOSXSetDrawingEnabled) (TkWindow *winPtr, int flag); /* 52 */ - void (*reserved53)(void); - void * (*tkMacOSXDrawable) (Drawable drawable); /* 54 */ #endif /* AQUA */ #if !(defined(_WIN32) || defined(__CYGWIN__) || defined(MAC_OSX_TK)) /* X11 */ void (*tkCreateXEventSource) (void); /* 0 */ @@ -680,9 +675,6 @@ extern const TkIntPlatStubs *tkIntPlatStubsPtr; (tkIntPlatStubsPtr->tkGenWMDestroyEvent) /* 51 */ #define TkMacOSXSetDrawingEnabled \ (tkIntPlatStubsPtr->tkMacOSXSetDrawingEnabled) /* 52 */ -/* Slot 53 is reserved */ -#define TkMacOSXDrawable \ - (tkIntPlatStubsPtr->tkMacOSXDrawable) /* 54 */ #endif /* AQUA */ #if !(defined(_WIN32) || defined(__CYGWIN__) || defined(MAC_OSX_TK)) /* X11 */ #define TkCreateXEventSource \ @@ -749,6 +741,10 @@ extern const TkIntPlatStubs *tkIntPlatStubsPtr; /* !END!: Do not edit above this line. */ +#ifndef TK_NO_DEPRECATED +# define TkMacOSXDrawable Tk_MacOSXGetNSWindowForDrawable +#endif + #undef TCL_STORAGE_CLASS #define TCL_STORAGE_CLASS DLLIMPORT diff --git a/generic/tkMain.c b/generic/tkMain.c index af1c550..c41715b 100644 --- a/generic/tkMain.c +++ b/generic/tkMain.c @@ -187,7 +187,7 @@ Tk_MainEx( * Ensure that we are getting a compatible version of Tcl. */ - if (Tcl_InitStubs(interp, "8.6-", 0) == NULL) { + if (Tcl_InitStubs(interp, "8.7-", 0) == NULL) { if (Tcl_InitStubs(interp, "8.1", 0) == NULL) { abort(); } else { diff --git a/generic/tkOldConfig.c b/generic/tkOldConfig.c index bb44763..7e902db 100644 --- a/generic/tkOldConfig.c +++ b/generic/tkOldConfig.c @@ -61,7 +61,7 @@ static void DeleteSpecCacheTable(void *clientData, * will hold an error message. * * Side effects: - * The fields of widgRec get filled in with information from argc/argv + * The fields of widgRec get filled in with information from objc/objv * and the option database. Old information in widgRec's fields gets * recycled. A copy of the spec-table is taken with (some of) the char* * fields converted into Tk_Uid fields; this copy will be released when @@ -76,9 +76,9 @@ Tk_ConfigureWidget( Tk_Window tkwin, /* Window containing widget (needed to set up * X resources). */ const Tk_ConfigSpec *specs, /* Describes legal options. */ - Tcl_Size argc, /* Number of elements in argv. */ - const char **argv, /* Command-line options. */ - char *widgRec, /* Record whose fields are to be modified. + Tcl_Size objc, /* Number of elements in objv. */ + Tcl_Obj *const *objv, /* Command-line options. */ + void *widgRec, /* Record whose fields are to be modified. * Values must be properly initialized. */ int flags) /* Used to specify additional flags that must * be present in config specs for them to be @@ -125,18 +125,10 @@ Tk_ConfigureWidget( * match entries in the specs. */ - for ( ; argc > 0; argc -= 2, argv += 2) { + for ( ; objc > 0; objc -= 2, objv += 2) { const char *arg; - if (flags & TK_CONFIG_OBJS) { - arg = Tcl_GetString((Tcl_Obj *) *argv); - } else { -#if defined(TK_NO_DEPRECATED) || (TK_MAJOR_VERSION > 8) - Tcl_Panic("Flag TK_CONFIG_OBJS is mandatory"); -#else - arg = *argv; -#endif - } + arg = Tcl_GetString(*objv); specPtr = FindConfigSpec(interp, staticSpecs, arg, needFlags, hateFlags); if (specPtr == NULL) { return TCL_ERROR; @@ -146,21 +138,13 @@ Tk_ConfigureWidget( * Process the entry. */ - if (argc < 2) { + if (objc < 2) { Tcl_SetObjResult(interp, Tcl_ObjPrintf( "value for \"%s\" missing", arg)); Tcl_SetErrorCode(interp, "TK", "VALUE_MISSING", NULL); return TCL_ERROR; } - if (flags & TK_CONFIG_OBJS) { - arg = Tcl_GetString((Tcl_Obj *) argv[1]); - } else { -#if defined(TK_NO_DEPRECATED) || (TK_MAJOR_VERSION > 8) - Tcl_Panic("Flag TK_CONFIG_OBJS is mandatory"); -#else - arg = argv[1]; -#endif - } + arg = Tcl_GetString(objv[1]); if (DoConfig(interp, tkwin, specPtr, arg, 0, widgRec) != TCL_OK) { Tcl_AppendObjToErrorInfo(interp, Tcl_ObjPrintf( "\n (processing \"%.40s\" option)",specPtr->argvName)); @@ -608,7 +592,7 @@ Tk_ConfigureInfo( Tcl_Interp *interp, /* Interpreter for error reporting. */ Tk_Window tkwin, /* Window corresponding to widgRec. */ const Tk_ConfigSpec *specs, /* Describes legal options. */ - char *widgRec, /* Record whose fields contain current values + void *widgRec, /* Record whose fields contain current values * for options. */ const char *argvName, /* If non-NULL, indicates a single option * whose info is to be returned. Otherwise @@ -922,7 +906,7 @@ Tk_ConfigureValue( Tcl_Interp *interp, /* Interpreter for error reporting. */ Tk_Window tkwin, /* Window corresponding to widgRec. */ const Tk_ConfigSpec *specs, /* Describes legal options. */ - char *widgRec, /* Record whose fields contain current values + void *widgRec, /* Record whose fields contain current values * for options. */ const char *argvName, /* Gives the command-line name for the option * whose value is to be returned. */ @@ -990,7 +974,7 @@ Tk_ConfigureValue( void Tk_FreeOptions( const Tk_ConfigSpec *specs, /* Describes legal options. */ - char *widgRec, /* Record whose fields contain current values + void *widgRec, /* Record whose fields contain current values * for options. */ Display *display, /* X display; needed for freeing some * resources. */ @@ -1008,7 +992,7 @@ Tk_FreeOptions( if (specPtr->offset < 0) { continue; } - ptr = widgRec + specPtr->offset; + ptr = (char *)widgRec + specPtr->offset; switch (specPtr->type) { case TK_CONFIG_STRING: if (*((char **) ptr) != NULL) { diff --git a/generic/tkRectOval.c b/generic/tkRectOval.c index 67b9d2b..626451c 100644 --- a/generic/tkRectOval.c +++ b/generic/tkRectOval.c @@ -171,7 +171,7 @@ Tk_ItemType tkRectangleType = { RectOvalCoords, /* coordProc */ DeleteRectOval, /* deleteProc */ DisplayRectOval, /* displayProc */ - TK_CONFIG_OBJS, /* flags */ + 0, /* flags */ RectToPoint, /* pointProc */ RectToArea, /* areaProc */ RectOvalToPostscript, /* postscriptProc */ @@ -196,7 +196,7 @@ Tk_ItemType tkOvalType = { RectOvalCoords, /* coordProc */ DeleteRectOval, /* deleteProc */ DisplayRectOval, /* displayProc */ - TK_CONFIG_OBJS, /* flags */ + 0, /* flags */ OvalToPoint, /* pointProc */ OvalToArea, /* areaProc */ RectOvalToPostscript, /* postscriptProc */ @@ -416,7 +416,7 @@ ConfigureRectOval( tkwin = Tk_CanvasTkwin(canvas); if (TCL_OK != Tk_ConfigureWidget(interp, tkwin, configSpecs, objc, - (const char **)objv, (char *) rectOvalPtr, flags|TK_CONFIG_OBJS)) { + objv, rectOvalPtr, flags)) { return TCL_ERROR; } state = itemPtr->state; diff --git a/generic/tkScrollbar.c b/generic/tkScrollbar.c index dbe2c62..f21af6e 100644 --- a/generic/tkScrollbar.c +++ b/generic/tkScrollbar.c @@ -287,16 +287,16 @@ ScrollbarWidgetObjCmd( goto error; } result = Tk_ConfigureValue(interp, scrollPtr->tkwin, - configSpecs, (char *) scrollPtr, Tcl_GetString(objv[2]), 0); + configSpecs, scrollPtr, Tcl_GetString(objv[2]), 0); break; } case COMMAND_CONFIGURE: { if (objc == 2) { result = Tk_ConfigureInfo(interp, scrollPtr->tkwin, - configSpecs, (char *) scrollPtr, NULL, 0); + configSpecs, scrollPtr, NULL, 0); } else if (objc == 3) { result = Tk_ConfigureInfo(interp, scrollPtr->tkwin, - configSpecs, (char *) scrollPtr, Tcl_GetString(objv[2]), 0); + configSpecs, scrollPtr, Tcl_GetString(objv[2]), 0); } else { result = ConfigureScrollbar(interp, scrollPtr, objc-2, objv+2, TK_CONFIG_ARGV_ONLY); @@ -474,7 +474,7 @@ ConfigureScrollbar( int flags) /* Flags to pass to Tk_ConfigureWidget. */ { if (Tk_ConfigureWidget(interp, scrollPtr->tkwin, configSpecs, objc, - (const char **)objv, (char *) scrollPtr, flags|TK_CONFIG_OBJS) != TCL_OK) { + objv, scrollPtr, flags) != TCL_OK) { return TCL_ERROR; } @@ -548,7 +548,7 @@ TkScrollbarEventProc( * Tk_FreeOptions handle all the standard option-related stuff. */ - Tk_FreeOptions(configSpecs, (char*) scrollPtr, scrollPtr->display, 0); + Tk_FreeOptions(configSpecs, scrollPtr, scrollPtr->display, 0); Tcl_EventuallyFree(scrollPtr, TCL_DYNAMIC); } else if (eventPtr->type == ConfigureNotify) { TkpComputeScrollbarGeometry(scrollPtr); diff --git a/generic/tkStubInit.c b/generic/tkStubInit.c index dc7947f..a5c6460 100644 --- a/generic/tkStubInit.c +++ b/generic/tkStubInit.c @@ -42,8 +42,6 @@ MODULE_SCOPE const TkStubs tkStubs; #undef TkPutImage #undef XPutImage -#define TkMacOSXDrawable Tk_MacOSXGetNSWindowForDrawable - #if !defined(MAC_OSX_TK) static int doNothing(void) @@ -535,8 +533,6 @@ static const TkIntPlatStubs tkIntPlatStubs = { TkGenerateButtonEvent, /* 50 */ TkGenWMDestroyEvent, /* 51 */ TkMacOSXSetDrawingEnabled, /* 52 */ - 0, /* 53 */ - TkMacOSXDrawable, /* 54 */ #endif /* AQUA */ #if !(defined(_WIN32) || defined(__CYGWIN__) || defined(MAC_OSX_TK)) /* X11 */ TkCreateXEventSource, /* 0 */ diff --git a/generic/tkTest.c b/generic/tkTest.c index e776bbf..e688a7e 100644 --- a/generic/tkTest.c +++ b/generic/tkTest.c @@ -240,7 +240,7 @@ Tktest_Init( { static int initialized = 0; - if (Tcl_InitStubs(interp, "8.6-", 0) == NULL) { + if (Tcl_InitStubs(interp, "8.7-", 0) == NULL) { return TCL_ERROR; } if (Tk_InitStubs(interp, TK_VERSION, 0) == NULL) { diff --git a/generic/tkText.c b/generic/tkText.c index 51fa2a0..ff58398 100644 --- a/generic/tkText.c +++ b/generic/tkText.c @@ -27,16 +27,6 @@ #include "tkWinInt.h" #endif -/* - * For compatibility with Tk 4.0 through 8.4.x, we allow tabs to be - * mis-specified with non-increasing values. These are converted into tabs - * which are the equivalent of at least a character width apart. - */ - -#if (TK_MAJOR_VERSION < 9) -#define _TK_ALLOW_DECREASING_TABS -#endif - #include "tkText.h" /* @@ -4568,27 +4558,12 @@ TkTextGetTabs( * illegal. */ -#ifdef _TK_ALLOW_DECREASING_TABS - /* - * Force the tab to be a typical character width to the right of - * the previous one, and update the 'lastStop' with the changed - * position. - */ - - if (textPtr->charWidth > 0) { - tabPtr->location = (tabPtr-1)->location + textPtr->charWidth; - } else { - tabPtr->location = (tabPtr-1)->location + 8; - } - lastStop = tabPtr->location; -#else Tcl_SetObjResult(interp, Tcl_ObjPrintf( "tabs must be monotonically increasing, but \"%s\" is " "smaller than or equal to the previous tab", Tcl_GetString(objv[i]))); Tcl_SetErrorCode(interp, "TK", "VALUE", "TAB_STOP", NULL); goto error; -#endif /* _TK_ALLOW_DECREASING_TABS */ } tabArrayPtr->numTabs++; diff --git a/generic/tkWindow.c b/generic/tkWindow.c index b3731bf..4aa903d 100644 --- a/generic/tkWindow.c +++ b/generic/tkWindow.c @@ -3181,7 +3181,7 @@ Initialize( * Ensure that we are getting a compatible version of Tcl. */ - if (Tcl_InitStubs(interp, "8.6-", 0) == NULL) { + if (Tcl_InitStubs(interp, "8.7-", 0) == NULL) { return TCL_ERROR; } |