Re: vwait behavior
- From: Schelte Bron <nospam@xxxxxxxxxx>
- Date: Sat, 08 Mar 2008 14:03:07 +0100
Donald Arseneau wrote:
On Mar 5, 8:46 pm, rfwoode...@xxxxxxx wrote:
Is there something wrong with the way I'm implementing the pause
proc that causes some weird behavior?
# pauses for n milliseconds
proc pause { {msecs 1000} } {
global gv;
after $msecs "set vpause 1"
vwait vpause
}
My guess is you are crashing due to stack overflow.
I expected the problem was that vwait waits for the local variable
vpause while the after sets the global variable vpause. The vwait
man page also indicates that the variable must be "globally scoped
(either with a call to global for the varName, or with the full
namespace path specification)." However, my experiments seem to
contradict this. Does vwait always work on global variables? Was
this changed at some point? Shouldn't the man page then also be
updated?
Schelte.
--
set Reply-To [string map {nospam schelte} $header(From)]
.
- Follow-Ups:
- Re: vwait behavior
- From: Alexandre Ferrieux
- Re: vwait behavior
- References:
- vwait behavior
- From: rfwooden84
- Re: vwait behavior
- From: Donald Arseneau
- vwait behavior
- Prev by Date: Re: Tk is not finding font
- Next by Date: Re: ttk::button foreground.
- Previous by thread: Re: vwait behavior
- Next by thread: Re: vwait behavior
- Index(es):