diff options
author | jenglish <jenglish@flightlab.com> | 2013-02-27 14:41:41 (GMT) |
---|---|---|
committer | jenglish <jenglish@flightlab.com> | 2013-02-27 14:41:41 (GMT) |
commit | 2b76c49e30421aa22968c63e57c49bfaa6238e2f (patch) | |
tree | e4c799bd7715375437a5ca9333297d2092c73630 /generic/tkFont.c | |
parent | b83ed80002d8d8eb676c9f7c81a794e8216e3498 (diff) | |
download | tk-2b76c49e30421aa22968c63e57c49bfaa6238e2f.zip tk-2b76c49e30421aa22968c63e57c49bfaa6238e2f.tar.gz tk-2b76c49e30421aa22968c63e57c49bfaa6238e2f.tar.bz2 |
Revert [ac229dabaa]. There is a reason the Tcl_GetIndexFromObj wrapper
exists and is used.
Diffstat (limited to 'generic/tkFont.c')
-rw-r--r-- | generic/tkFont.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/generic/tkFont.c b/generic/tkFont.c index ed9b813..4485df8 100644 --- a/generic/tkFont.c +++ b/generic/tkFont.c @@ -486,8 +486,8 @@ Tk_FontObjCmd( Tcl_WrongNumArgs(interp, 1, objv, "option ?arg?"); return TCL_ERROR; } - if (Tcl_GetIndexFromObjStruct(interp, objv[1], optionStrings, - sizeof(char *), "option", 0, &index) != TCL_OK) { + if (Tcl_GetIndexFromObj(interp, objv[1], optionStrings, "option", 0, + &index) != TCL_OK) { return TCL_ERROR; } @@ -763,8 +763,8 @@ Tk_FontObjCmd( fmPtr->ascent, fmPtr->descent, fmPtr->ascent + fmPtr->descent, fmPtr->fixed)); } else { - if (Tcl_GetIndexFromObjStruct(interp, objv[3], switches, - sizeof(char *), "metric", 0, &index) != TCL_OK) { + if (Tcl_GetIndexFromObj(interp, objv[3], switches, "metric", 0, + &index) != TCL_OK) { Tk_FreeFont(tkfont); return TCL_ERROR; } @@ -3368,8 +3368,8 @@ ConfigAttributesObj( optionPtr = objv[i]; valuePtr = objv[i + 1]; - if (Tcl_GetIndexFromObjStruct(interp, optionPtr, fontOpt, - sizeof(char *), "option", 1, &index) != TCL_OK) { + if (Tcl_GetIndexFromObj(interp, optionPtr, fontOpt, "option", 1, + &index) != TCL_OK) { return TCL_ERROR; } if ((i+2 >= objc) && (objc & 1)) { @@ -3468,8 +3468,8 @@ GetAttributeInfoObj( start = 0; end = FONT_NUMFIELDS; if (objPtr != NULL) { - if (Tcl_GetIndexFromObjStruct(interp, objPtr, fontOpt, - sizeof(char *), "option", TCL_EXACT, &index) != TCL_OK) { + if (Tcl_GetIndexFromObj(interp, objPtr, fontOpt, "option", TCL_EXACT, + &index) != TCL_OK) { return TCL_ERROR; } start = index; |