diff options
-rw-r--r-- | generic/tkCanvPs.c | 4 | ||||
-rw-r--r-- | generic/tkText.c | 76 | ||||
-rw-r--r-- | generic/tkTextDisp.c | 28 | ||||
-rw-r--r-- | generic/tkTextImage.c | 12 | ||||
-rw-r--r-- | generic/tkTextIndex.c | 2 | ||||
-rw-r--r-- | generic/tkTextMark.c | 6 | ||||
-rw-r--r-- | generic/tkTextTag.c | 16 | ||||
-rw-r--r-- | generic/tkTextWind.c | 20 | ||||
-rw-r--r-- | macosx/tkMacOSXButton.c | 10 | ||||
-rw-r--r-- | macosx/tkMacOSXClipboard.c | 2 | ||||
-rw-r--r-- | macosx/tkMacOSXEmbed.c | 20 | ||||
-rw-r--r-- | macosx/tkMacOSXHLEvents.c | 16 | ||||
-rw-r--r-- | macosx/tkMacOSXImage.c | 22 | ||||
-rw-r--r-- | macosx/tkMacOSXInit.c | 4 | ||||
-rw-r--r-- | macosx/tkMacOSXMenubutton.c | 8 | ||||
-rw-r--r-- | macosx/tkMacOSXNotify.c | 16 | ||||
-rw-r--r-- | macosx/tkMacOSXPrint.c | 4 | ||||
-rw-r--r-- | macosx/tkMacOSXScale.c | 6 | ||||
-rw-r--r-- | macosx/tkMacOSXScrlbr.c | 6 | ||||
-rw-r--r-- | macosx/tkMacOSXSend.c | 2 | ||||
-rw-r--r-- | macosx/tkMacOSXSysTray.c | 2 | ||||
-rw-r--r-- | macosx/tkMacOSXWindowEvent.c | 6 | ||||
-rw-r--r-- | macosx/tkMacOSXWm.c | 14 |
23 files changed, 152 insertions, 150 deletions
diff --git a/generic/tkCanvPs.c b/generic/tkCanvPs.c index 3b2c7c3..e62d4ba 100644 --- a/generic/tkCanvPs.c +++ b/generic/tkCanvPs.c @@ -1196,11 +1196,13 @@ GetPostscriptPoints( #if defined(_WIN32) || defined(MAC_OSX_TK) static void TkImageGetColor( - TCL_UNUSED(TkColormapData *), + TkColormapData *cdata, unsigned long pixel, /* Pixel value to look up */ double *red, double *green, double *blue) /* Color data to return */ { + (void)cdata; + *red = (double) GetRValue(pixel) / 255.0; *green = (double) GetGValue(pixel) / 255.0; *blue = (double) GetBValue(pixel) / 255.0; diff --git a/generic/tkText.c b/generic/tkText.c index a1ab880..d535428 100644 --- a/generic/tkText.c +++ b/generic/tkText.c @@ -87,15 +87,15 @@ static const char *const insertUnfocussedStrings[] = { * freeing. */ -static int SetLineStartEnd(ClientData clientData, +static int SetLineStartEnd(void *clientData, Tcl_Interp *interp, Tk_Window tkwin, Tcl_Obj **value, char *recordPtr, Tcl_Size internalOffset, char *oldInternalPtr, int flags); -static Tcl_Obj * GetLineStartEnd(ClientData clientData, +static Tcl_Obj * GetLineStartEnd(void *clientData, Tk_Window tkwin, char *recordPtr, Tcl_Size internalOffset); -static void RestoreLineStartEnd(ClientData clientData, +static void RestoreLineStartEnd(void *clientData, Tk_Window tkwin, char *internalPtr, char *oldInternalPtr); static int ObjectIsEmpty(Tcl_Obj *objPtr); @@ -272,7 +272,7 @@ typedef ClientData SearchAddLineProc(int lineNum, int *extraLinesPtr); typedef int SearchMatchProc(int lineNum, struct SearchSpec *searchSpecPtr, - ClientData clientData, Tcl_Obj *theLine, + void *clientData, Tcl_Obj *theLine, Tcl_Size matchOffset, Tcl_Size matchLength); typedef int SearchLineIndexProc(Tcl_Interp *interp, Tcl_Obj *objPtr, struct SearchSpec *searchSpecPtr, @@ -313,7 +313,7 @@ typedef struct SearchSpec { SearchLineIndexProc *lineIndexProc; /* Function to call when we have found a * match. */ - ClientData clientData; /* Information about structure being searched, + void *clientData; /* Information about structure being searched, * in this case a text widget. */ } SearchSpec; @@ -352,14 +352,14 @@ static void DestroyText(TkText *textPtr); static int InsertChars(TkSharedText *sharedTextPtr, TkText *textPtr, TkTextIndex *indexPtr, Tcl_Obj *stringPtr, int viewUpdate); -static void TextBlinkProc(ClientData clientData); -static void TextCmdDeletedProc(ClientData clientData); +static void TextBlinkProc(void *clientData); +static void TextCmdDeletedProc(void *clientData); static int CreateWidget(TkSharedText *sharedPtr, Tk_Window tkwin, Tcl_Interp *interp, const TkText *parent, int objc, Tcl_Obj *const objv[]); -static void TextEventProc(ClientData clientData, +static void TextEventProc(void *clientData, XEvent *eventPtr); -static Tcl_Size TextFetchSelection(ClientData clientData, Tcl_Size offset, +static Tcl_Size TextFetchSelection(void *clientData, Tcl_Size offset, char *buffer, Tcl_Size maxBytes); static int TextIndexSortProc(const void *first, const void *second); @@ -375,13 +375,13 @@ static int TextSearchCmd(TkText *textPtr, Tcl_Interp *interp, int objc, Tcl_Obj *const objv[]); static int TextEditCmd(TkText *textPtr, Tcl_Interp *interp, int objc, Tcl_Obj *const objv[]); -static int TextWidgetObjCmd(ClientData clientData, +static int TextWidgetObjCmd(void *clientData, Tcl_Interp *interp, int objc, Tcl_Obj *const objv[]); -static int SharedTextObjCmd(ClientData clientData, +static int SharedTextObjCmd(void *clientData, Tcl_Interp *interp, int objc, Tcl_Obj *const objv[]); -static void TextWorldChangedCallback(ClientData instanceData); +static void TextWorldChangedCallback(void *instanceData); static void TextWorldChanged(TkText *textPtr, int mask); static int TextDumpCmd(TkText *textPtr, Tcl_Interp *interp, int objc, Tcl_Obj *const objv[]); @@ -450,7 +450,7 @@ static const Tk_ClassProcs textClass = { int Tk_TextObjCmd( - ClientData clientData, /* Main window associated with interpreter. */ + void *clientData, /* Main window associated with interpreter. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ @@ -688,7 +688,7 @@ CreateWidget( static int TextWidgetObjCmd( - ClientData clientData, /* Information about text widget. */ + void *clientData, /* Information about text widget. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ @@ -1596,7 +1596,7 @@ TextWidgetObjCmd( static int SharedTextObjCmd( - ClientData clientData, /* Information about shared test B-tree. */ + void *clientData, /* Information about shared test B-tree. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ @@ -2124,7 +2124,7 @@ ConfigureText( } if (start > end) { Tcl_SetObjResult(interp, Tcl_NewStringObj( - "-startline must be less than or equal to -endline", -1)); + "-startline must be less than or equal to -endline", TCL_INDEX_NONE)); Tcl_SetErrorCode(interp, "TK", "TEXT", "INDEX_ORDER", NULL); Tk_RestoreSavedOptions(&savedOptions); return TCL_ERROR; @@ -2374,7 +2374,7 @@ ConfigureText( static void TextWorldChangedCallback( - ClientData instanceData) /* Information about widget. */ + void *instanceData) /* Information about widget. */ { TkText *textPtr = (TkText *)instanceData; @@ -2464,7 +2464,7 @@ TextWorldChanged( static void TextEventProc( - ClientData clientData, /* Information about window. */ + void *clientData, /* Information about window. */ XEvent *eventPtr) /* Information about event. */ { TkText *textPtr = (TkText *)clientData; @@ -2574,7 +2574,7 @@ TextEventProc( static void TextCmdDeletedProc( - ClientData clientData) /* Pointer to widget record for widget. */ + void *clientData) /* Pointer to widget record for widget. */ { TkText *textPtr = (TkText *)clientData; Tk_Window tkwin = textPtr->tkwin; @@ -2810,13 +2810,13 @@ TextPushUndoAction( Tcl_IncrRefCount(index2Obj); Tcl_ListObjAppendElement(NULL, seeInsertObj, - Tcl_NewStringObj(Tk_PathName(textPtr->tkwin), -1)); + Tcl_NewStringObj(Tk_PathName(textPtr->tkwin), TCL_INDEX_NONE)); Tcl_ListObjAppendElement(NULL, seeInsertObj, Tcl_NewStringObj("see", 3)); Tcl_ListObjAppendElement(NULL, seeInsertObj, Tcl_NewStringObj("insert", 6)); Tcl_ListObjAppendElement(NULL, markSet1InsertObj, - Tcl_NewStringObj(Tk_PathName(textPtr->tkwin), -1)); + Tcl_NewStringObj(Tk_PathName(textPtr->tkwin), TCL_INDEX_NONE)); Tcl_ListObjAppendElement(NULL, markSet1InsertObj, Tcl_NewStringObj("mark", 4)); Tcl_ListObjAppendElement(NULL, markSet1InsertObj, @@ -2843,7 +2843,7 @@ TextPushUndoAction( Tcl_ListObjAppendElement(NULL, deleteCmdObj, index2Obj); Tcl_ListObjAppendElement(NULL, markSetLUndoMarkCmdObj, - Tcl_NewStringObj(Tk_PathName(textPtr->tkwin), -1)); + Tcl_NewStringObj(Tk_PathName(textPtr->tkwin), TCL_INDEX_NONE)); Tcl_ListObjAppendElement(NULL, markSetLUndoMarkCmdObj, Tcl_NewStringObj("mark", 4)); Tcl_ListObjAppendElement(NULL, markSetLUndoMarkCmdObj, @@ -2854,23 +2854,23 @@ TextPushUndoAction( strcat(lMarkName, stringUndoMarkId); strcat(rMarkName, stringUndoMarkId); Tcl_ListObjAppendElement(NULL, markSetLUndoMarkCmdObj, - Tcl_NewStringObj(lMarkName, -1)); + Tcl_NewStringObj(lMarkName, TCL_INDEX_NONE)); Tcl_ListObjAppendElement(NULL, markSetRUndoMarkCmdObj, - Tcl_NewStringObj(rMarkName, -1)); + Tcl_NewStringObj(rMarkName, TCL_INDEX_NONE)); Tcl_ListObjAppendElement(NULL, markSetLUndoMarkCmdObj, index1Obj); Tcl_ListObjAppendElement(NULL, markSetRUndoMarkCmdObj, index2Obj); Tcl_ListObjAppendElement(NULL, markGravityLUndoMarkCmdObj, - Tcl_NewStringObj(Tk_PathName(textPtr->tkwin), -1)); + Tcl_NewStringObj(Tk_PathName(textPtr->tkwin), TCL_INDEX_NONE)); Tcl_ListObjAppendElement(NULL, markGravityLUndoMarkCmdObj, Tcl_NewStringObj("mark", 4)); Tcl_ListObjAppendElement(NULL, markGravityLUndoMarkCmdObj, Tcl_NewStringObj("gravity", 7)); markGravityRUndoMarkCmdObj = Tcl_DuplicateObj(markGravityLUndoMarkCmdObj); Tcl_ListObjAppendElement(NULL, markGravityLUndoMarkCmdObj, - Tcl_NewStringObj(lMarkName, -1)); + Tcl_NewStringObj(lMarkName, TCL_INDEX_NONE)); Tcl_ListObjAppendElement(NULL, markGravityRUndoMarkCmdObj, - Tcl_NewStringObj(rMarkName, -1)); + Tcl_NewStringObj(rMarkName, TCL_INDEX_NONE)); Tcl_ListObjAppendElement(NULL, markGravityLUndoMarkCmdObj, Tcl_NewStringObj("left", 4)); Tcl_ListObjAppendElement(NULL, markGravityRUndoMarkCmdObj, @@ -2954,7 +2954,7 @@ TextPushUndoAction( int TextUndoRedoCallback( Tcl_Interp *interp, /* Current interpreter. */ - ClientData clientData, /* Passed from undo code, but contains our + void *clientData, /* Passed from undo code, but contains our * shared text data structure. */ Tcl_Obj *objPtr) /* Arguments of a command to be handled by the * shared text data structure. */ @@ -3009,7 +3009,7 @@ TextUndoRedoCallback( * allow it to take place here. */ - cmdNameObj = Tcl_NewStringObj(Tk_PathName(textPtr->tkwin), -1); + cmdNameObj = Tcl_NewStringObj(Tk_PathName(textPtr->tkwin), TCL_INDEX_NONE); Tcl_ListObjAppendElement(NULL, evalObj, cmdNameObj); Tcl_ListObjAppendList(NULL, evalObj, objPtr); res = Tcl_EvalObjEx(interp, evalObj, TCL_EVAL_GLOBAL); @@ -3406,7 +3406,7 @@ DeleteIndexRange( static Tcl_Size TextFetchSelection( - ClientData clientData, /* Information about text widget. */ + void *clientData, /* Information about text widget. */ Tcl_Size offset, /* Offset within selection of first character * to be returned. */ char *buffer, /* Location in which to place selection. */ @@ -3544,7 +3544,7 @@ TextFetchSelection( void TkTextLostSelection( - ClientData clientData) /* Information about text widget. */ + void *clientData) /* Information about text widget. */ { TkText *textPtr = (TkText *)clientData; @@ -3629,7 +3629,7 @@ TkTextSelectionEvent( static void TextBlinkProc( - ClientData clientData) /* Pointer to record describing text. */ + void *clientData) /* Pointer to record describing text. */ { TkText *textPtr = (TkText *)clientData; TkTextIndex index; @@ -3863,7 +3863,7 @@ TextSearchCmd( case TK_TEXT_SEARCH_COUNT: if (i >= objc-1) { Tcl_SetObjResult(interp, Tcl_NewStringObj( - "no value given for \"-count\" option", -1)); + "no value given for \"-count\" option", TCL_INDEX_NONE)); Tcl_SetErrorCode(interp, "TK", "TEXT", "VALUE", NULL); return TCL_ERROR; } @@ -3917,7 +3917,7 @@ TextSearchCmd( if (searchSpec.noLineStop && searchSpec.exact) { Tcl_SetObjResult(interp, Tcl_NewStringObj( "the \"-nolinestop\" option requires the \"-regexp\" option" - " to be present", -1)); + " to be present", TCL_INDEX_NONE)); Tcl_SetErrorCode(interp, "TK", "TEXT", "SEARCH_USAGE", NULL); return TCL_ERROR; } @@ -3925,7 +3925,7 @@ TextSearchCmd( if (searchSpec.overlap && !searchSpec.all) { Tcl_SetObjResult(interp, Tcl_NewStringObj( "the \"-overlap\" option requires the \"-all\" option" - " to be present", -1)); + " to be present", TCL_INDEX_NONE)); Tcl_SetErrorCode(interp, "TK", "TEXT", "SEARCH_USAGE", NULL); return TCL_ERROR; } @@ -4252,7 +4252,7 @@ static int TextSearchFoundMatch( int lineNum, /* Line on which match was found. */ SearchSpec *searchSpecPtr, /* Search parameters. */ - ClientData clientData, /* Token returned by the 'addNextLineProc', + void *clientData, /* Token returned by the 'addNextLineProc', * TextSearchAddNextLine. May be NULL, in * which we case we must generate it (from * lineNum). */ @@ -5588,7 +5588,7 @@ UpdateDirtyFlag( void TkTextRunAfterSyncCmd( - ClientData clientData) /* Information about text widget. */ + void *clientData) /* Information about text widget. */ { TkText *textPtr = (TkText *)clientData; int code; @@ -5851,7 +5851,7 @@ SearchCore( Tcl_IncrRefCount(theLine); for (passes = 0; passes < 2; ) { - ClientData lineInfo; + void *lineInfo; int linesSearched = 1; int extraLinesSearched = 0; diff --git a/generic/tkTextDisp.c b/generic/tkTextDisp.c index d7890df..c818691 100644 --- a/generic/tkTextDisp.c +++ b/generic/tkTextDisp.c @@ -570,7 +570,7 @@ static void DisplayDLine(TkText *textPtr, DLine *dlPtr, DLine *prevPtr, Pixmap pixmap); static void DisplayLineBackground(TkText *textPtr, DLine *dlPtr, DLine *prevPtr, Pixmap pixmap); -static void DisplayText(ClientData clientData); +static void DisplayText(void *clientData); static DLine * FindDLine(TkText *textPtr, DLine *dlPtr, const TkTextIndex *indexPtr); static void FreeDLines(TkText *textPtr, DLine *firstPtr, @@ -617,9 +617,9 @@ static int TextGetScrollInfoObj(Tcl_Interp *interp, TkText *textPtr, int objc, Tcl_Obj *const objv[], double *dblPtr, int *intPtr); -static void AsyncUpdateLineMetrics(ClientData clientData); +static void AsyncUpdateLineMetrics(void *clientData); static void GenerateWidgetViewSyncEvent(TkText *textPtr, Bool InSync); -static void AsyncUpdateYScrollbar(ClientData clientData); +static void AsyncUpdateYScrollbar(void *clientData); static int IsStartOfNotMergedLine(TkText *textPtr, const TkTextIndex *indexPtr); @@ -3013,7 +3013,7 @@ DisplayLineBackground( static void AsyncUpdateLineMetrics( - ClientData clientData) /* Information about widget. */ + void *clientData) /* Information about widget. */ { TkText *textPtr = (TkText *)clientData; TextDInfo *dInfoPtr = textPtr->dInfoPtr; @@ -4171,7 +4171,7 @@ TkTextUpdateOneLine( static void DisplayText( - ClientData clientData) /* Information about widget. */ + void *clientData) /* Information about widget. */ { TkText *textPtr = (TkText *)clientData; TextDInfo *dInfoPtr = textPtr->dInfoPtr; @@ -6540,10 +6540,10 @@ GetXView( Tcl_PrintDouble(NULL, first, buf1+1); Tcl_PrintDouble(NULL, last, buf2+1); Tcl_DStringInit(&buf); - Tcl_DStringAppend(&buf, textPtr->xScrollCmd, -1); - Tcl_DStringAppend(&buf, buf1, -1); - Tcl_DStringAppend(&buf, buf2, -1); - code = Tcl_EvalEx(interp, Tcl_DStringValue(&buf), -1, TCL_EVAL_GLOBAL); + Tcl_DStringAppend(&buf, textPtr->xScrollCmd, TCL_INDEX_NONE); + Tcl_DStringAppend(&buf, buf1, TCL_INDEX_NONE); + Tcl_DStringAppend(&buf, buf2, TCL_INDEX_NONE); + code = Tcl_EvalEx(interp, Tcl_DStringValue(&buf), TCL_INDEX_NONE, TCL_EVAL_GLOBAL); Tcl_DStringFree(&buf); if (code != TCL_OK) { Tcl_AddErrorInfo(interp, @@ -6825,10 +6825,10 @@ GetYView( Tcl_PrintDouble(NULL, first, buf1+1); Tcl_PrintDouble(NULL, last, buf2+1); Tcl_DStringInit(&buf); - Tcl_DStringAppend(&buf, textPtr->yScrollCmd, -1); - Tcl_DStringAppend(&buf, buf1, -1); - Tcl_DStringAppend(&buf, buf2, -1); - code = Tcl_EvalEx(interp, Tcl_DStringValue(&buf), -1, TCL_EVAL_GLOBAL); + Tcl_DStringAppend(&buf, textPtr->yScrollCmd, TCL_INDEX_NONE); + Tcl_DStringAppend(&buf, buf1, TCL_INDEX_NONE); + Tcl_DStringAppend(&buf, buf2, TCL_INDEX_NONE); + code = Tcl_EvalEx(interp, Tcl_DStringValue(&buf), TCL_INDEX_NONE, TCL_EVAL_GLOBAL); Tcl_DStringFree(&buf); if (code != TCL_OK) { Tcl_AddErrorInfo(interp, @@ -6858,7 +6858,7 @@ GetYView( static void AsyncUpdateYScrollbar( - ClientData clientData) /* Information about widget. */ + void *clientData) /* Information about widget. */ { TkText *textPtr = (TkText *)clientData; diff --git a/generic/tkTextImage.c b/generic/tkTextImage.c index 760ac22..00f9c34 100644 --- a/generic/tkTextImage.c +++ b/generic/tkTextImage.c @@ -50,7 +50,7 @@ static int EmbImageLayoutProc(TkText *textPtr, Tcl_Size offset, int maxX, Tcl_Size maxChars, int noCharsYet, TkWrapMode wrapMode, TkTextDispChunk *chunkPtr); -static void EmbImageProc(ClientData clientData, int x, int y, +static void EmbImageProc(void *clientData, int x, int y, int width, int height, int imageWidth, int imageHeight); @@ -389,7 +389,7 @@ EmbImageConfigure( if (name == NULL) { Tcl_SetObjResult(textPtr->interp, Tcl_NewStringObj( "Either a \"-name\" or a \"-image\" argument must be" - " provided to the \"image create\" subcommand", -1)); + " provided to the \"image create\" subcommand", TCL_INDEX_NONE)); Tcl_SetErrorCode(textPtr->interp, "TK", "TEXT", "IMAGE_CREATE_USAGE", NULL); return TCL_ERROR; @@ -414,19 +414,19 @@ EmbImageConfigure( } Tcl_DStringInit(&newName); - Tcl_DStringAppend(&newName, name, -1); + Tcl_DStringAppend(&newName, name, TCL_INDEX_NONE); if (conflict) { char buf[4 + TCL_INTEGER_SPACE]; snprintf(buf, sizeof(buf), "#%d", count+1); - Tcl_DStringAppend(&newName, buf, -1); + Tcl_DStringAppend(&newName, buf, TCL_INDEX_NONE); } name = Tcl_DStringValue(&newName); hPtr = Tcl_CreateHashEntry(&textPtr->sharedTextPtr->imageTable, name, &dummy); Tcl_SetHashValue(hPtr, eiPtr); - Tcl_SetObjResult(textPtr->interp, Tcl_NewStringObj(name, -1)); + Tcl_SetObjResult(textPtr->interp, Tcl_NewStringObj(name, TCL_INDEX_NONE)); eiPtr->body.ei.name = (char *)ckalloc(Tcl_DStringLength(&newName) + 1); strcpy(eiPtr->body.ei.name, name); Tcl_DStringFree(&newName); @@ -837,7 +837,7 @@ TkTextImageIndex( static void EmbImageProc( - ClientData clientData, /* Pointer to widget record. */ + void *clientData, /* Pointer to widget record. */ TCL_UNUSED(int), /* Upper left pixel (within image) that must * be redisplayed. */ TCL_UNUSED(int), diff --git a/generic/tkTextIndex.c b/generic/tkTextIndex.c index eb9baf5..2449a12 100644 --- a/generic/tkTextIndex.c +++ b/generic/tkTextIndex.c @@ -800,7 +800,7 @@ GetIndex( */ Tcl_DStringInit(©); - p = strrchr(Tcl_DStringAppend(©, string, -1), '.'); + p = strrchr(Tcl_DStringAppend(©, string, TCL_INDEX_NONE), '.'); if (p != NULL) { TkTextSearch search; TkTextTag *tagPtr; diff --git a/generic/tkTextMark.c b/generic/tkTextMark.c index c302ca0..ca3cba0 100644 --- a/generic/tkTextMark.c +++ b/generic/tkTextMark.c @@ -157,7 +157,7 @@ TkTextMarkCmd( } else { typeStr = "left"; } - Tcl_SetObjResult(interp, Tcl_NewStringObj(typeStr, -1)); + Tcl_SetObjResult(interp, Tcl_NewStringObj(typeStr, TCL_INDEX_NONE)); return TCL_OK; } str = Tcl_GetStringFromObj(objv[4],&length); @@ -188,9 +188,9 @@ TkTextMarkCmd( } resultObj = Tcl_NewObj(); Tcl_ListObjAppendElement(NULL, resultObj, Tcl_NewStringObj( - "insert", -1)); + "insert", TCL_INDEX_NONE)); Tcl_ListObjAppendElement(NULL, resultObj, Tcl_NewStringObj( - "current", -1)); + "current", TCL_INDEX_NONE)); for (hPtr = Tcl_FirstHashEntry(&textPtr->sharedTextPtr->markTable, &search); hPtr != NULL; hPtr = Tcl_NextHashEntry(&search)) { Tcl_ListObjAppendElement(NULL, resultObj, Tcl_NewStringObj( diff --git a/generic/tkTextTag.c b/generic/tkTextTag.c index 10b6e1c..235fc52 100644 --- a/generic/tkTextTag.c +++ b/generic/tkTextTag.c @@ -280,7 +280,7 @@ TkTextTagCmd( (void *) tagPtr->name, Tcl_GetString(objv[4])); Tcl_SetObjResult(interp, Tcl_NewStringObj( "requested illegal events; only key, button, motion," - " enter, leave, and virtual events may be used", -1)); + " enter, leave, and virtual events may be used", TCL_INDEX_NONE)); Tcl_SetErrorCode(interp, "TK", "TEXT", "TAG_BIND_EVENT",NULL); return TCL_ERROR; } @@ -304,7 +304,7 @@ TkTextTagCmd( } Tcl_ResetResult(interp); } else { - Tcl_SetObjResult(interp, Tcl_NewStringObj(command, -1)); + Tcl_SetObjResult(interp, Tcl_NewStringObj(command, TCL_INDEX_NONE)); } } else { Tk_GetAllBindings(interp, textPtr->sharedTextPtr->bindingTable, @@ -723,11 +723,11 @@ TkTextTagCmd( resultObj = Tcl_NewObj(); TkTextPrintIndex(textPtr, &tSearch.curIndex, position); Tcl_ListObjAppendElement(NULL, resultObj, - Tcl_NewStringObj(position, -1)); + Tcl_NewStringObj(position, TCL_INDEX_NONE)); TkBTreeNextTag(&tSearch); TkTextPrintIndex(textPtr, &tSearch.curIndex, position); Tcl_ListObjAppendElement(NULL, resultObj, - Tcl_NewStringObj(position, -1)); + Tcl_NewStringObj(position, TCL_INDEX_NONE)); Tcl_SetObjResult(interp, resultObj); break; } @@ -838,9 +838,9 @@ TkTextTagCmd( gotPrevIndexPair: resultObj = Tcl_NewObj(); Tcl_ListObjAppendElement(NULL, resultObj, - Tcl_NewStringObj(position1, -1)); + Tcl_NewStringObj(position1, TCL_INDEX_NONE)); Tcl_ListObjAppendElement(NULL, resultObj, - Tcl_NewStringObj(position2, -1)); + Tcl_NewStringObj(position2, TCL_INDEX_NONE)); Tcl_SetObjResult(interp, resultObj); break; } @@ -1405,7 +1405,7 @@ ChangeTagPriority( void TkTextBindProc( - ClientData clientData, /* Pointer to text widget structure. */ + void *clientData, /* Pointer to text widget structure. */ XEvent *eventPtr) /* Pointer to X event that just happened. */ { TkText *textPtr = (TkText *)clientData; @@ -1750,7 +1750,7 @@ TagBindEvent( } } Tk_BindEvent(textPtr->sharedTextPtr->bindingTable, eventPtr, - textPtr->tkwin, numTags, (ClientData *) nameArrPtr); + textPtr->tkwin, numTags, (void **) nameArrPtr); if (numTags > NUM_BIND_TAGS) { ckfree(nameArrPtr); diff --git a/generic/tkTextWind.c b/generic/tkTextWind.c index e95ca34..391f836 100644 --- a/generic/tkTextWind.c +++ b/generic/tkTextWind.c @@ -20,9 +20,9 @@ * geometry manager: */ -static void EmbWinRequestProc(ClientData clientData, +static void EmbWinRequestProc(void *clientData, Tk_Window tkwin); -static void EmbWinLostContentProc(ClientData clientData, +static void EmbWinLostContentProc(void *clientData, Tk_Window tkwin); static const Tk_GeomMgr textGeomType = { @@ -52,14 +52,14 @@ static void EmbWinBboxProc(TkText *textPtr, int *widthPtr, int *heightPtr); static int EmbWinConfigure(TkText *textPtr, TkTextSegment *ewPtr, int objc, Tcl_Obj *const objv[]); -static void EmbWinDelayedUnmap(ClientData clientData); +static void EmbWinDelayedUnmap(void *clientData); static int EmbWinDeleteProc(TkTextSegment *segPtr, TkTextLine *linePtr, int treeGone); static int EmbWinLayoutProc(TkText *textPtr, TkTextIndex *indexPtr, TkTextSegment *segPtr, Tcl_Size offset, int maxX, Tcl_Size maxChars,int noCharsYet, TkWrapMode wrapMode, TkTextDispChunk *chunkPtr); -static void EmbWinStructureProc(ClientData clientData, +static void EmbWinStructureProc(void *clientData, XEvent *eventPtr); static void EmbWinUndisplayProc(TkText *textPtr, TkTextDispChunk *chunkPtr); @@ -521,7 +521,7 @@ EmbWinConfigure( static void EmbWinStructureProc( - ClientData clientData, /* Pointer to record describing window item. */ + void *clientData, /* Pointer to record describing window item. */ XEvent *eventPtr) /* Describes what just happened. */ { TkTextEmbWindowClient *client = (TkTextEmbWindowClient *)clientData; @@ -567,7 +567,7 @@ EmbWinStructureProc( static void EmbWinRequestProc( - ClientData clientData, /* Pointer to record for window item. */ + void *clientData, /* Pointer to record for window item. */ TCL_UNUSED(Tk_Window)) /* Window that changed its desired size. */ { TkTextEmbWindowClient *client = (TkTextEmbWindowClient *)clientData; @@ -611,7 +611,7 @@ EmbWinRequestProc( static void EmbWinLostContentProc( - ClientData clientData, /* Pointer to record describing window item. */ + void *clientData, /* Pointer to record describing window item. */ Tk_Window tkwin) /* Window that was claimed away by another * geometry manager. */ { @@ -908,10 +908,10 @@ EmbWinLayoutProc( if (dsPtr != NULL) { Tcl_DStringAppend(dsPtr, before, (int) (string-before)); - code = Tcl_EvalEx(textPtr->interp, Tcl_DStringValue(dsPtr), -1, TCL_EVAL_GLOBAL); + code = Tcl_EvalEx(textPtr->interp, Tcl_DStringValue(dsPtr), TCL_INDEX_NONE, TCL_EVAL_GLOBAL); Tcl_DStringFree(dsPtr); } else { - code = Tcl_EvalEx(textPtr->interp, ewPtr->body.ew.create, -1, TCL_EVAL_GLOBAL); + code = Tcl_EvalEx(textPtr->interp, ewPtr->body.ew.create, TCL_INDEX_NONE, TCL_EVAL_GLOBAL); } if (code != TCL_OK) { Tcl_BackgroundException(textPtr->interp, code); @@ -1300,7 +1300,7 @@ EmbWinBboxProc( static void EmbWinDelayedUnmap( - ClientData clientData) /* Token for the window to be unmapped. */ + void *clientData) /* Token for the window to be unmapped. */ { TkTextEmbWindowClient *client = (TkTextEmbWindowClient *)clientData; diff --git a/macosx/tkMacOSXButton.c b/macosx/tkMacOSXButton.c index 06e4593..26d0c33 100644 --- a/macosx/tkMacOSXButton.c +++ b/macosx/tkMacOSXButton.c @@ -76,7 +76,7 @@ static void ButtonContentDrawCB(const HIRect *bounds, ThemeButtonKind kind, const HIThemeButtonDrawInfo *info, MacButton *ptr, SInt16 depth, Boolean isColorDev); -static void ButtonEventProc(ClientData clientData, +static void ButtonEventProc(void *clientData, XEvent *eventPtr); static void TkMacOSXComputeButtonParams(TkButton *butPtr, ThemeButtonKind *btnkind, @@ -86,7 +86,7 @@ static int TkMacOSXComputeButtonDrawParams(TkButton *butPtr, static void TkMacOSXDrawButton(MacButton *butPtr, GC gc, Pixmap pixmap); static void DrawButtonImageAndText(TkButton *butPtr); -static void PulseDefaultButtonProc(ClientData clientData); +static void PulseDefaultButtonProc(void *clientData); /* * The class procedure table for the button widgets. @@ -179,7 +179,7 @@ TkpCreateButton( void TkpDisplayButton( - ClientData clientData) /* Information about widget. */ + void *clientData) /* Information about widget. */ { MacButton *macButtonPtr = (MacButton *)clientData; TkButton *butPtr = (TkButton *)clientData; @@ -900,7 +900,7 @@ ButtonContentDrawCB ( static void ButtonEventProc( - ClientData clientData, /* Information about window. */ + void *clientData, /* Information about window. */ XEvent *eventPtr) /* Information about event. */ { TkButton *buttonPtr = (TkButton *)clientData; @@ -1174,7 +1174,7 @@ TkMacOSXComputeButtonDrawParams( */ static void -PulseDefaultButtonProc(ClientData clientData) +PulseDefaultButtonProc(void *clientData) { MacButton *mbPtr = (MacButton *)clientData; diff --git a/macosx/tkMacOSXClipboard.c b/macosx/tkMacOSXClipboard.c index c5df750..272469e 100644 --- a/macosx/tkMacOSXClipboard.c +++ b/macosx/tkMacOSXClipboard.c @@ -118,7 +118,7 @@ TkSelGetSelection( * returned. */ Tk_GetSelProc *proc, /* Procedure to call to process the selection, * once it has been retrieved. */ - ClientData clientData) /* Arbitrary value to pass to proc. */ + void *clientData) /* Arbitrary value to pass to proc. */ { int result = TCL_ERROR; TkDisplay *dispPtr = ((TkWindow *) tkwin)->dispPtr; diff --git a/macosx/tkMacOSXEmbed.c b/macosx/tkMacOSXEmbed.c index 0002de9..3494818 100644 --- a/macosx/tkMacOSXEmbed.c +++ b/macosx/tkMacOSXEmbed.c @@ -48,14 +48,14 @@ static Container *firstContainerPtr = NULL; * Prototypes for static procedures defined in this file: */ -static void ContainerEventProc(ClientData clientData, XEvent *eventPtr); -static void EmbeddedEventProc(ClientData clientData, XEvent *eventPtr); -static void EmbedActivateProc(ClientData clientData, XEvent *eventPtr); -static void EmbedFocusProc(ClientData clientData, XEvent *eventPtr); +static void ContainerEventProc(void *clientData, XEvent *eventPtr); +static void EmbeddedEventProc(void *clientData, XEvent *eventPtr); +static void EmbedActivateProc(void *clientData, XEvent *eventPtr); +static void EmbedFocusProc(void *clientData, XEvent *eventPtr); static void EmbedGeometryRequest(Container *containerPtr, int width, int height); static void EmbedSendConfigure(Container *containerPtr); -static void EmbedStructureProc(ClientData clientData, XEvent *eventPtr); +static void EmbedStructureProc(void *clientData, XEvent *eventPtr); static void EmbedWindowDeleted(TkWindow *winPtr); /* @@ -702,7 +702,7 @@ Tk_GetOtherWindow( static void EmbeddedEventProc( - ClientData clientData, /* Token for container window. */ + void *clientData, /* Token for container window. */ XEvent *eventPtr) /* ResizeRequest event. */ { TkWindow *winPtr = (TkWindow *)clientData; @@ -737,7 +737,7 @@ EmbeddedEventProc( static void ContainerEventProc( - ClientData clientData, /* Token for container window. */ + void *clientData, /* Token for container window. */ XEvent *eventPtr) /* ResizeRequest event. */ { TkWindow *winPtr = (TkWindow *)clientData; @@ -845,7 +845,7 @@ ContainerEventProc( static void EmbedStructureProc( - ClientData clientData, /* Token for container window. */ + void *clientData, /* Token for container window. */ XEvent *eventPtr) /* ResizeRequest event. */ { Container *containerPtr = (Container *)clientData; @@ -899,7 +899,7 @@ EmbedStructureProc( static void EmbedActivateProc( - ClientData clientData, /* Token for container window. */ + void *clientData, /* Token for container window. */ XEvent *eventPtr) /* ResizeRequest event. */ { Container *containerPtr = (Container *)clientData; @@ -934,7 +934,7 @@ EmbedActivateProc( static void EmbedFocusProc( - ClientData clientData, /* Token for container window. */ + void *clientData, /* Token for container window. */ XEvent *eventPtr) /* ResizeRequest event. */ { Container *containerPtr = (Container *)clientData; diff --git a/macosx/tkMacOSXHLEvents.c b/macosx/tkMacOSXHLEvents.c index af09f83..ee99fce 100644 --- a/macosx/tkMacOSXHLEvents.c +++ b/macosx/tkMacOSXHLEvents.c @@ -48,7 +48,7 @@ typedef struct AppleEventInfo { static int MissedAnyParameters(const AppleEvent *theEvent); static int ReallyKillMe(Tcl_Event *eventPtr, int flags); -static void ProcessAppleEvent(ClientData clientData); +static void ProcessAppleEvent(void *clientData); /* * Names of the procedures which can be used to process AppleEvents. @@ -240,9 +240,9 @@ static const char getSdefProc[] = "::tk::mac::GetDynamicSdef"; AEInfo->replyEvent = nil; AEInfo->retryCount = 0; if (Tcl_FindCommand(_eventInterp, "::tk::mac::OpenDocuments", NULL, 0)){ - ProcessAppleEvent((ClientData)AEInfo); + ProcessAppleEvent((void *)AEInfo); } else { - Tcl_CreateTimerHandler(500, ProcessAppleEvent, (ClientData)AEInfo); + Tcl_CreateTimerHandler(500, ProcessAppleEvent, (void *)AEInfo); } } @@ -263,7 +263,7 @@ static const char getSdefProc[] = "::tk::mac::GetDynamicSdef"; AEInfo->procedure = printDocProc; AEInfo->replyEvent = nil; AEInfo->retryCount = 0; - ProcessAppleEvent((ClientData)AEInfo); + ProcessAppleEvent((void *)AEInfo); } - (void) handleDoScriptEvent: (NSAppleEventDescriptor *)event @@ -325,7 +325,7 @@ static const char getSdefProc[] = "::tk::mac::GetDynamicSdef"; AEInfo->procedure = scriptFileProc; AEInfo->replyEvent = nil; AEInfo->retryCount = 0; - ProcessAppleEvent((ClientData)AEInfo); + ProcessAppleEvent((void *)AEInfo); } } } else if (noErr == AEGetParamPtr(theDesc, keyDirectObject, typeUTF8Text, &type, @@ -379,7 +379,7 @@ static const char getSdefProc[] = "::tk::mac::GetDynamicSdef"; AEInfo->procedure = launchURLProc; AEInfo->replyEvent = nil; AEInfo->retryCount = 0; - ProcessAppleEvent((ClientData)AEInfo); + ProcessAppleEvent((void *)AEInfo); } - (void)handleGetSDEFEvent:(NSAppleEventDescriptor *)event withReplyEvent:(NSAppleEventDescriptor *)replyEvent { @@ -394,7 +394,7 @@ static const char getSdefProc[] = "::tk::mac::GetDynamicSdef"; AEInfo->procedure = getSdefProc; AEInfo->replyEvent = nil; AEInfo->retryCount = 0; - ProcessAppleEvent((ClientData)AEInfo); + ProcessAppleEvent((void *)AEInfo); } @@ -426,7 +426,7 @@ static const char getSdefProc[] = "::tk::mac::GetDynamicSdef"; */ static void ProcessAppleEvent( - ClientData clientData) + void *clientData) { int code; AppleEventInfo *AEInfo = (AppleEventInfo*) clientData; diff --git a/macosx/tkMacOSXImage.c b/macosx/tkMacOSXImage.c index 9169530..a540946 100644 --- a/macosx/tkMacOSXImage.c +++ b/macosx/tkMacOSXImage.c @@ -1077,15 +1077,15 @@ struct TkMacOSXNSImageModel { static int TkMacOSXNSImageCreate(Tcl_Interp *interp, const char *name, Tcl_Size objc, Tcl_Obj *const objv[], const Tk_ImageType *typePtr, Tk_ImageModel model, - ClientData *clientDataPtr); -static ClientData TkMacOSXNSImageGet(Tk_Window tkwin, ClientData clientData); -static void TkMacOSXNSImageDisplay(ClientData clientData, + void **clientDataPtr); +static void *TkMacOSXNSImageGet(Tk_Window tkwin, void *clientData); +static void TkMacOSXNSImageDisplay(void *clientData, Display *display, Drawable drawable, int imageX, int imageY, int width, int height, int drawableX, int drawableY); -static void TkMacOSXNSImageFree(ClientData clientData, Display *display); -static void TkMacOSXNSImageDelete(ClientData clientData); +static void TkMacOSXNSImageFree(void *clientData, Display *display); +static void TkMacOSXNSImageDelete(void *clientData); static Tk_ImageType TkMacOSXNSImageType = { "nsimage", /* name of image type */ @@ -1394,7 +1394,7 @@ TkMacOSXNSImageConfigureModel( int TkMacOSXNSImageObjCmd( - ClientData clientData, /* Information about the image model. */ + void *clientData, /* Information about the image model. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ @@ -1486,7 +1486,7 @@ TkMacOSXNSImageCreate( * including image name or type). */ TCL_UNUSED(const Tk_ImageType *), /* typePtr */ Tk_ImageModel model, /* Token for image, to be used in callbacks. */ - ClientData *clientDataPtr) /* Store manager's token for image here; it + void **clientDataPtr) /* Store manager's token for image here; it * will be returned in later callbacks. */ { TkMacOSXNSImageModel *modelPtr; @@ -1535,7 +1535,7 @@ TkMacOSXNSImageCreate( *---------------------------------------------------------------------- */ -static ClientData +static void * TkMacOSXNSImageGet( TCL_UNUSED(Tk_Window), /* tkwin */ void *clientData) /* Pointer to TkMacOSXNSImageModel for image. */ @@ -1566,7 +1566,7 @@ TkMacOSXNSImageGet( static void TkMacOSXNSImageDisplay( - ClientData clientData, /* Pointer to TkMacOSXNSImageInstance for image. */ + void *clientData, /* Pointer to TkMacOSXNSImageInstance for image. */ TCL_UNUSED(Display *), /* display */ Drawable drawable, /* Where to draw or redraw image. */ int imageX, int imageY, /* Origin of area to redraw, relative to @@ -1654,7 +1654,7 @@ TkMacOSXNSImageDisplay( static void TkMacOSXNSImageFree( - ClientData clientData, /* Pointer to TkMacOSXNSImageInstance for instance. */ + void *clientData, /* Pointer to TkMacOSXNSImageInstance for instance. */ TCL_UNUSED(Display *)) /* display */ { TkMacOSXNSImageInstance *instPtr = (TkMacOSXNSImageInstance *) clientData; @@ -1679,7 +1679,7 @@ TkMacOSXNSImageFree( static void TkMacOSXNSImageDelete( - ClientData clientData) /* Pointer to TkMacOSXNSImageModel for image. When + void *clientData) /* Pointer to TkMacOSXNSImageModel for image. When * this function is called, no more instances * exist. */ { diff --git a/macosx/tkMacOSXInit.c b/macosx/tkMacOSXInit.c index 039d1d1..2430504 100644 --- a/macosx/tkMacOSXInit.c +++ b/macosx/tkMacOSXInit.c @@ -35,7 +35,7 @@ static char scriptPath[PATH_MAX + 1] = ""; static int TkMacOSXGetAppPathObjCmd(TCL_UNUSED(void *), Tcl_Interp *ip, int objc, Tcl_Obj *const objv[]); -static int TkMacOSVersionObjCmd(ClientData cd, Tcl_Interp *ip, +static int TkMacOSVersionObjCmd(void *cd, Tcl_Interp *ip, int objc, Tcl_Obj *const objv[]); #pragma mark TKApplication(TKInit) @@ -780,7 +780,7 @@ TkpGetAppName( static int TkMacOSVersionObjCmd( - TCL_UNUSED(void *), /* ClientData */ + TCL_UNUSED(void *), Tcl_Interp *interp, int objc, Tcl_Obj *const objv[]) diff --git a/macosx/tkMacOSXMenubutton.c b/macosx/tkMacOSXMenubutton.c index fcb7999..ac7befd 100644 --- a/macosx/tkMacOSXMenubutton.c +++ b/macosx/tkMacOSXMenubutton.c @@ -49,7 +49,7 @@ typedef struct MacMenuButton { * Forward declarations for static functions defined later in this file: */ -static void MenuButtonEventProc(ClientData clientData, +static void MenuButtonEventProc(void *clientData, XEvent *eventPtr); static void MenuButtonBackgroundDrawCB(MacMenuButton *ptr, SInt16 depth, Boolean isColorDev); @@ -57,7 +57,7 @@ static void MenuButtonContentDrawCB(ThemeButtonKind kind, const HIThemeButtonDrawInfo *info, MacMenuButton *ptr, SInt16 depth, Boolean isColorDev); -static void MenuButtonEventProc(ClientData clientData, +static void MenuButtonEventProc(void *clientData, XEvent *eventPtr); static void TkMacOSXComputeMenuButtonParams(TkMenuButton *butPtr, ThemeButtonKind *btnkind, @@ -163,7 +163,7 @@ TkpCreateMenuButton( void TkpDisplayMenuButton( - ClientData clientData) /* Information about widget. */ + void *clientData) /* Information about widget. */ { MacMenuButton *mbPtr = (MacMenuButton *)clientData; TkMenuButton *butPtr = (TkMenuButton *)clientData; @@ -682,7 +682,7 @@ MenuButtonContentDrawCB ( static void MenuButtonEventProc( - ClientData clientData, /* Information about window. */ + void *clientData, /* Information about window. */ XEvent *eventPtr) /* Information about event. */ { TkMenuButton *buttonPtr = (TkMenuButton *)clientData; diff --git a/macosx/tkMacOSXNotify.c b/macosx/tkMacOSXNotify.c index 19441c5..8d8966e 100644 --- a/macosx/tkMacOSXNotify.c +++ b/macosx/tkMacOSXNotify.c @@ -55,9 +55,9 @@ static Tcl_ThreadDataKey dataKey; #define TSD_INIT() ThreadSpecificData *tsdPtr = (ThreadSpecificData *) \ Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData)) -static void TkMacOSXNotifyExitHandler(ClientData clientData); -static void TkMacOSXEventsSetupProc(ClientData clientData, int flags); -static void TkMacOSXEventsCheckProc(ClientData clientData, int flags); +static void TkMacOSXNotifyExitHandler(void *clientData); +static void TkMacOSXEventsSetupProc(void *clientData, int flags); +static void TkMacOSXEventsCheckProc(void *clientData, int flags); #ifdef TK_MAC_DEBUG_EVENTS static const char *Tk_EventName[39] = { @@ -104,7 +104,7 @@ static const char *Tk_EventName[39] = { static Tk_RestrictAction InspectQueueRestrictProc( - ClientData arg, + void *arg, XEvent *eventPtr) { XVirtualEvent* ve = (XVirtualEvent*) eventPtr; @@ -128,7 +128,7 @@ InspectQueueRestrictProc( void DebugPrintQueue(void) { - ClientData oldArg; + void *oldArg; Tk_RestrictProc *oldProc; oldProc = Tk_RestrictEvents(InspectQueueRestrictProc, NULL, &oldArg); @@ -321,7 +321,7 @@ Tk_MacOSXSetupTkNotifier(void) static void TkMacOSXNotifyExitHandler( - ClientData dummy) /* Not used. */ + void *dummy) /* Not used. */ { (void)dummy; TSD_INIT(); @@ -369,7 +369,7 @@ TkMacOSXNotifyExitHandler( void TkMacOSXDrawAllViews( - ClientData clientData) + void *clientData) { int count = 0, *dirtyCount = (int *)clientData; @@ -453,7 +453,7 @@ static const Tcl_Time zeroBlockTime = { 0, 0 }; static void TkMacOSXEventsSetupProc( - ClientData dummy, + void *dummy, int flags) { NSString *runloopMode = [[NSRunLoop currentRunLoop] currentMode]; diff --git a/macosx/tkMacOSXPrint.c b/macosx/tkMacOSXPrint.c index f81f8bd..3ebfa29 100644 --- a/macosx/tkMacOSXPrint.c +++ b/macosx/tkMacOSXPrint.c @@ -26,7 +26,7 @@ /* Forward declarations of functions and variables. */ NSString * fileName = nil; CFStringRef urlFile = NULL; -int StartPrint(ClientData clientData, Tcl_Interp * interp, +int StartPrint(void *clientData, Tcl_Interp * interp, int objc, Tcl_Obj * const objv[]); OSStatus FinishPrint(NSString *file, int buttonValue); int MacPrint_Init(Tcl_Interp * interp); @@ -75,7 +75,7 @@ int MacPrint_Init(Tcl_Interp * interp); int StartPrint( - ClientData clientData, + void *clientData, Tcl_Interp * interp, int objc, Tcl_Obj *const objv[]) diff --git a/macosx/tkMacOSXScale.c b/macosx/tkMacOSXScale.c index bc2a87e..a66bba7 100644 --- a/macosx/tkMacOSXScale.c +++ b/macosx/tkMacOSXScale.c @@ -51,7 +51,7 @@ static ControlActionUPP scaleActionProc = NULL; /* Pointer to func. */ * Forward declarations for procedures defined later in this file: */ -static void MacScaleEventProc(ClientData clientData, +static void MacScaleEventProc(void *clientData, XEvent *eventPtr); static pascal void ScaleActionProc(ControlRef theControl, ControlPartCode partCode); @@ -139,7 +139,7 @@ TkpDestroyScale( void TkpDisplayScale( - ClientData clientData) /* Widget record for scale. */ + void *clientData) /* Widget record for scale. */ { TkScale *scalePtr = clientData; Tk_Window tkwin = scalePtr->tkwin; @@ -378,7 +378,7 @@ TkpScaleElement( static void MacScaleEventProc( - ClientData clientData, /* Information about window. */ + void *clientData, /* Information about window. */ XEvent *eventPtr) /* Information about event. */ { MacScale *macScalePtr = (MacScale *) clientData; diff --git a/macosx/tkMacOSXScrlbr.c b/macosx/tkMacOSXScrlbr.c index 954498d..eb1c99a 100644 --- a/macosx/tkMacOSXScrlbr.c +++ b/macosx/tkMacOSXScrlbr.c @@ -95,7 +95,7 @@ static ScrollbarMetrics metrics = { * Declarations of static functions defined later in this file: */ -static void ScrollbarEventProc(ClientData clientData, +static void ScrollbarEventProc(void *clientData, XEvent *eventPtr); static int ScrollbarEvent(TkScrollbar *scrollPtr, XEvent *eventPtr); @@ -244,7 +244,7 @@ static void drawMacScrollbar( void TkpDisplayScrollbar( - ClientData clientData) /* Information about window. */ + void *clientData) /* Information about window. */ { TkScrollbar *scrollPtr = (TkScrollbar *)clientData; MacScrollbar *msPtr = (MacScrollbar *) scrollPtr; @@ -766,7 +766,7 @@ ScrollbarEvent( static void ScrollbarEventProc( - ClientData clientData, /* Information about window. */ + void *clientData, /* Information about window. */ XEvent *eventPtr) /* Information about event. */ { TkScrollbar *scrollPtr = (TkScrollbar *)clientData; diff --git a/macosx/tkMacOSXSend.c b/macosx/tkMacOSXSend.c index 101da1d..5471083 100644 --- a/macosx/tkMacOSXSend.c +++ b/macosx/tkMacOSXSend.c @@ -321,7 +321,7 @@ Tk_SetAppName( int Tk_SendObjCmd( - ClientData dummy, /* Not used */ + void *dummy, /* Not used */ Tcl_Interp *interp, /* The interp we are sending from */ int objc, /* Number of arguments */ Tcl_Obj *const objv[]) /* The arguments */ diff --git a/macosx/tkMacOSXSysTray.c b/macosx/tkMacOSXSysTray.c index c2e347f..3de6216 100644 --- a/macosx/tkMacOSXSysTray.c +++ b/macosx/tkMacOSXSysTray.c @@ -162,7 +162,7 @@ typedef TkStatusItem** StatusItemInfo; static void MacSystrayDestroy( - ClientData clientData, + void *clientData, TCL_UNUSED(Tcl_Interp *)) { StatusItemInfo info = (StatusItemInfo)clientData; diff --git a/macosx/tkMacOSXWindowEvent.c b/macosx/tkMacOSXWindowEvent.c index e6c5584..77146e2 100644 --- a/macosx/tkMacOSXWindowEvent.c +++ b/macosx/tkMacOSXWindowEvent.c @@ -945,7 +945,7 @@ Tk_MacOSXIsAppInFront(void) static Tk_RestrictAction ExposeRestrictProc( - ClientData arg, + void *arg, XEvent *eventPtr) { return (eventPtr->type==Expose && eventPtr->xany.serial==PTR2UINT(arg) @@ -1089,7 +1089,7 @@ ConfigureRestrictProc( if (winPtr) { unsigned int width = (unsigned int)newsize.width; unsigned int height=(unsigned int)newsize.height; - ClientData oldArg; + void *oldArg; Tk_RestrictProc *oldProc; /* @@ -1154,7 +1154,7 @@ ConfigureRestrictProc( int updatesNeeded; CGRect updateBounds; TkWindow *winPtr = TkMacOSXGetTkWindow([self window]); - ClientData oldArg; + void *oldArg; Tk_RestrictProc *oldProc; if (!winPtr) { return; diff --git a/macosx/tkMacOSXWm.c b/macosx/tkMacOSXWm.c index 558adf7..c0ccd9a 100644 --- a/macosx/tkMacOSXWm.c +++ b/macosx/tkMacOSXWm.c @@ -178,7 +178,7 @@ static int wmTracing = 0; * of top-level windows. */ -static void TopLevelReqProc(ClientData dummy, Tk_Window tkwin); +static void TopLevelReqProc(void *dummy, Tk_Window tkwin); static const Tk_GeomMgr wmMgrType = { "wm", /* name */ @@ -200,11 +200,11 @@ static NSRect InitialWindowBounds(TkWindow *winPtr, NSWindow *macWindow); static int ParseGeometry(Tcl_Interp *interp, char *string, TkWindow *winPtr); -static void TopLevelEventProc(ClientData clientData, +static void TopLevelEventProc(void *clientData, XEvent *eventPtr); static void WmStackorderToplevelWrapperMap(TkWindow *winPtr, Display *display, Tcl_HashTable *table); -static void UpdateGeometryInfo(ClientData clientData); +static void UpdateGeometryInfo(void *clientData); static void UpdateSizeHints(TkWindow *winPtr); static void UpdateVRootGeometry(WmInfo *wmPtr); static int WmAspectCmd(Tk_Window tkwin, TkWindow *winPtr, @@ -1154,7 +1154,7 @@ TkWmSetClass( int Tk_WmObjCmd( - ClientData clientData, /* Main window associated with interpreter. */ + void *clientData, /* Main window associated with interpreter. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ @@ -4171,7 +4171,7 @@ Tk_UnsetGrid( static void TopLevelEventProc( - ClientData clientData, /* Window for which event occurred. */ + void *clientData, /* Window for which event occurred. */ XEvent *eventPtr) /* Event that just happened. */ { TkWindow *winPtr = (TkWindow *)clientData; @@ -4258,7 +4258,7 @@ TopLevelReqProc( static void UpdateGeometryInfo( - ClientData clientData) /* Pointer to the window's record. */ + void *clientData) /* Pointer to the window's record. */ { TkWindow *winPtr = (TkWindow *)clientData; WmInfo *wmPtr = winPtr->wmInfoPtr; @@ -5666,7 +5666,7 @@ TkMacOSXZoomToplevel( int TkUnsupported1ObjCmd( - ClientData clientData, /* Main window associated with interpreter. */ + void *clientData, /* Main window associated with interpreter. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ |