This is the mail archive of the
xconq7@sources.redhat.com
mailing list for the Xconq project.
Re: side names are displayed with gray color
- From: Jim Kingdon <kingdon at panix dot com>
- To: hronne at pp dot sbbs dot se
- Cc: mniw at sol dot dti dot ne dot jp, xconq7 at sources dot redhat dot com
- Date: Mon, 15 Apr 2002 17:32:01 -0400 (EDT)
- Subject: Re: side names are displayed with gray color
- References: <l03130300b8e0e0e945d6@[217.115.39.11]>
> The problem seems to be that run_game must be called at least once
> before init_redraws in the tcltk interface in order to avoid this gray
> color.
Ah, I see, going to init_redraws and reading the code paths which
relate to sides leads me to the buggy code quickly enough. Patch
enclosed (which should be relatively self-explanatory: a everingame
flag of false is producing the gray and the call path is
init_redraws(C)->update_side_display(C)->update_game_side_info(tcl)).
> I am reluctant to change the startup sequence again since I don't want the
> synch errors back.
Of course not! The question is "does the contract for init_redraws
say that <something else, if so what?> must be called first?" And the
answer is no, that was just a bug in the tcltk part of the code.
2002-04-15 Jim Kingdon <kingdon@panix.com>
* tcltk/tkconq.tcl: If ingame and everingame are both set, set
fill to black (so a single call with everingame false doesn't make
it gray forever).
Index: tcltk/tkconq.tcl
===================================================================
RCS file: /cvs/xconq/xconq/tcltk/tkconq.tcl,v
retrieving revision 1.92
diff -u -r1.92 tkconq.tcl
--- tcltk/tkconq.tcl 14 Apr 2002 00:06:26 -0000 1.92
+++ tcltk/tkconq.tcl 15 Apr 2002 21:23:47 -0000
@@ -2616,6 +2616,8 @@
set bgcolor [ $sidelist cget -background ]
$sidelist itemconfig left$s -fill $bgcolor
$sidelist itemconfig resv$s -fill $bgcolor
+ } else {
+ $sidelist itemconfig s$s -fill black
}
if { $status > 0 } {
# Find the the victory laurels and move into visibility.