summaryrefslogtreecommitdiffstats
path: root/generic/tkCanvImg.c
diff options
context:
space:
mode:
authorstanton <stanton>1999-04-16 01:51:06 (GMT)
committerstanton <stanton>1999-04-16 01:51:06 (GMT)
commit03656f44f81469f459031fa3a4a7b09c8bc77712 (patch)
tree31378e81bd58f8c726fc552d6b30cbf3ca07497b /generic/tkCanvImg.c
parent404fc236f34304df53b7e44bc7971d786b87d453 (diff)
downloadtk-03656f44f81469f459031fa3a4a7b09c8bc77712.zip
tk-03656f44f81469f459031fa3a4a7b09c8bc77712.tar.gz
tk-03656f44f81469f459031fa3a4a7b09c8bc77712.tar.bz2
* Merged 8.1 branch into the main trunk
Diffstat (limited to 'generic/tkCanvImg.c')
-rw-r--r--generic/tkCanvImg.c16
1 files changed, 9 insertions, 7 deletions
diff --git a/generic/tkCanvImg.c b/generic/tkCanvImg.c
index 0432bd7..cf1106d 100644
--- a/generic/tkCanvImg.c
+++ b/generic/tkCanvImg.c
@@ -4,12 +4,12 @@
* This file implements image items for canvas widgets.
*
* Copyright (c) 1994 The Regents of the University of California.
- * Copyright (c) 1994-1996 Sun Microsystems, Inc.
+ * Copyright (c) 1994-1997 Sun Microsystems, Inc.
*
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkCanvImg.c,v 1.2 1998/09/14 18:23:05 stanton Exp $
+ * RCS: @(#) $Id: tkCanvImg.c,v 1.3 1999/04/16 01:51:11 stanton Exp $
*/
#include <stdio.h>
@@ -126,7 +126,7 @@ Tk_ItemType tkImageType = {
* Results:
* A standard Tcl return value. If an error occurred in
* creating the item, then an error message is left in
- * interp->result; in this case itemPtr is left uninitialized,
+ * the interp's result; in this case itemPtr is left uninitialized,
* so it can be safely freed by the caller.
*
* Side effects:
@@ -190,7 +190,7 @@ CreateImage(interp, canvas, itemPtr, argc, argv)
* details on what it does.
*
* Results:
- * Returns TCL_OK or TCL_ERROR, and sets interp->result.
+ * Returns TCL_OK or TCL_ERROR, and sets the interp's result.
*
* Side effects:
* The coordinates for the given item may be changed.
@@ -224,8 +224,10 @@ ImageCoords(interp, canvas, itemPtr, argc, argv)
}
ComputeImageBbox(canvas, imgPtr);
} else {
- sprintf(interp->result,
- "wrong # coordinates: expected 0 or 2, got %d", argc);
+ char buf[64];
+
+ sprintf(buf, "wrong # coordinates: expected 0 or 2, got %d", argc);
+ Tcl_SetResult(interp, buf, TCL_VOLATILE);
return TCL_ERROR;
}
return TCL_OK;
@@ -241,7 +243,7 @@ ImageCoords(interp, canvas, itemPtr, argc, argv)
*
* Results:
* A standard Tcl result code. If an error occurs, then
- * an error message is left in interp->result.
+ * an error message is left in the interp's result.
*
* Side effects:
* Configuration information may be set for itemPtr.