diff options
author | dkf <donal.k.fellows@manchester.ac.uk> | 2012-07-24 19:41:30 (GMT) |
---|---|---|
committer | dkf <donal.k.fellows@manchester.ac.uk> | 2012-07-24 19:41:30 (GMT) |
commit | a161a378971b948143b658e432ce13b723c25f89 (patch) | |
tree | 27a19c720909b8a4b9391764f0bf7e7598f9df24 /win/ttkWinXPTheme.c | |
parent | a7cecb5c00243f374eaf3d64c5905042633e888b (diff) | |
download | tk-a161a378971b948143b658e432ce13b723c25f89.zip tk-a161a378971b948143b658e432ce13b723c25f89.tar.gz tk-a161a378971b948143b658e432ce13b723c25f89.tar.bz2 |
a few more places
Diffstat (limited to 'win/ttkWinXPTheme.c')
-rw-r--r-- | win/ttkWinXPTheme.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/win/ttkWinXPTheme.c b/win/ttkWinXPTheme.c index 08e8a8e..a343216 100644 --- a/win/ttkWinXPTheme.c +++ b/win/ttkWinXPTheme.c @@ -1062,7 +1062,8 @@ GetSysFlagFromObj(Tcl_Interp *interp, Tcl_Obj *objPtr, int *resultPtr) if (Tcl_ListObjGetElements(interp, objPtr, &objc, &objv) != TCL_OK) return TCL_ERROR; if (objc != 2) { - Tcl_SetResult(interp, "wrong # args", TCL_STATIC); + Tcl_SetObjResult(interp, Tcl_NewStringObj("wrong # args", -1)); + Tcl_SetErrorCode(interp, "TCL", "WRONGARGS", NULL); return TCL_ERROR; } for (i = 0; i < objc; ++i) { @@ -1116,8 +1117,9 @@ Ttk_CreateVsapiElement( O_HALFHEIGHT, O_HALFWIDTH }; if (objc < 2) { - Tcl_AppendResult(interp, - "missing required arguments 'class' and/or 'partId'", NULL); + Tcl_SetObjResult(interp, Tcl_NewStringObj( + "missing required arguments 'class' and/or 'partId'", -1)); + Tcl_SetErrorCode(interp, "TCL", "VSAPI", "REQUIRED", NULL); return TCL_ERROR; } @@ -1132,8 +1134,10 @@ Ttk_CreateVsapiElement( for (i = 3; i < objc; i += 2) { int tmp = 0; if (i == objc -1) { - Tcl_AppendResult(interp, "Missing value for \"", - Tcl_GetString(objv[i]), "\".", NULL); + Tcl_SetObjResult(interp, Tcl_ObjPrintf( + "Missing value for \"%s\".", + Tcl_GetString(objv[i]))); + Tcl_SetErrorCode(interp, "TCL", "VSAPI", "MISSING", NULL); return TCL_ERROR; } if (Tcl_GetIndexFromObj(interp, objv[i], optionStrings, |