summaryrefslogtreecommitdiffstats
path: root/generic/tkCanvas.c
diff options
context:
space:
mode:
authornijtmans <nijtmans>2008-11-09 20:51:28 (GMT)
committernijtmans <nijtmans>2008-11-09 20:51:28 (GMT)
commitdf18c1fe67355d2bb0b36c28e8c9a66f1d5ae3c8 (patch)
treeb0eb47d8c31b341a93520b3ddc364fcb3e5077df /generic/tkCanvas.c
parent6bb91a5313a57dceb34e2cd3764971af61368408 (diff)
downloadtk-df18c1fe67355d2bb0b36c28e8c9a66f1d5ae3c8.zip
tk-df18c1fe67355d2bb0b36c28e8c9a66f1d5ae3c8.tar.gz
tk-df18c1fe67355d2bb0b36c28e8c9a66f1d5ae3c8.tar.bz2
make all Tk_CustomOption tables const and
remove unnecessary type cast
Diffstat (limited to 'generic/tkCanvas.c')
-rw-r--r--generic/tkCanvas.c14
1 files changed, 6 insertions, 8 deletions
diff --git a/generic/tkCanvas.c b/generic/tkCanvas.c
index bfdc2c8..a3a2bd9 100644
--- a/generic/tkCanvas.c
+++ b/generic/tkCanvas.c
@@ -12,7 +12,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkCanvas.c,v 1.56 2008/11/03 10:17:49 dkf Exp $
+ * RCS: @(#) $Id: tkCanvas.c,v 1.57 2008/11/09 20:51:28 nijtmans Exp $
*/
/* #define USE_OLD_TAG_SEARCH 1 */
@@ -102,15 +102,13 @@ typedef struct TagSearch {
* Custom option for handling "-state" and "-offset"
*/
-static Tk_CustomOption stateOption = {
- (Tk_OptionParseProc *) TkStateParseProc,
- TkStatePrintProc,
+static const Tk_CustomOption stateOption = {
+ TkStateParseProc, TkStatePrintProc,
(ClientData) NULL /* Only "normal" and "disabled". */
};
-static Tk_CustomOption offsetOption = {
- (Tk_OptionParseProc *) TkOffsetParseProc,
- TkOffsetPrintProc,
+static const Tk_CustomOption offsetOption = {
+ TkOffsetParseProc, TkOffsetPrintProc,
(ClientData) TK_OFFSET_RELATIVE
};
@@ -2007,7 +2005,7 @@ CanvasWidgetCmd(
}
FIRST_CANVAS_ITEM_MATCHING(objv[2], &searchPtr, goto done);
if (itemPtr != NULL) {
- Tcl_SetObjResult(interp,
+ Tcl_SetObjResult(interp,
Tcl_NewStringObj(itemPtr->typePtr->name, -1));
}
break;