Tcl/Tk 8.3 on X11: BadWindow and BadDrawable errors
Eric McDonald
emcdonal@cps.cmich.edu
Sat Jun 21 19:21:00 GMT 2003
I have been getting the following errors at the beginning of Xconq games using
the Tcl/Tk interface on X-Windows:
X error on display :0.0: BadWindow (invalid Window parameter)
X error on display :0.0: BadDrawable (invalid Pixmap or Window parameter)
I have traced them to an invocation of set_tool_cursor (in tkmap.c) with
which = 1, instead of 0. What I have gleaned from the code is that which = 1
indicates the view region for the world map, as opposed to the main
map.
Both maps _seem_ to be created okay, as I have walked through the mapw_cmd
call for each of them....
set_tool_cursor gets called 3 or 4 times for some autoscrolling of the main
map by the run_game_idle stuff, and everything is fine. Then the world map
cursor change is triggered in the following context:
#0 set_tool_cursor (map=0x88274e0, which=1) at tkmap.c:4502
#1 0x0804dc70 in update_world_mouseover (map=0x88274e0, rawx=183, rawy=147)
at tkmain.c:1547
#2 0x0804dc02 in tk_world_mouse_over_cmd (cldata=0x0, interp=0x818db18,
argc=4, argv=0xbfffefc0) at tkmain.c:1538
#3 0x400491d7 in TclInvokeStringCommand () from /usr/lib/libtcl8.3.so
and I get the above errors when Tk_DefineCursor is called with world map's
tkwin.
Has anyone else seen this?
Thanks,
Eric
More information about the Xconq7
mailing list