[prev in list] [next in list] [prev in thread] [next in thread] 

List:       visual-tcl
Subject:    AW: [vtcl] Using $widget(alias) calls in procs?
From:       Thanner Gerhard <Thanner () ubavie ! gv ! at>
Date:       1999-10-14 7:28:47
[Download RAW message or body]

The variable widget is an array containing all aliases you specify for your
widgets. Vtcl automatically declares it as global (just  look at the
beginning of your program). It also contains the real widgetnames for
example .top17.but5 or so.
So when you want to manipulate a widget from inside of a procedure you have
to declare "global widget" to make the contents of the array named widget
available to your procedure.

Gerhard Thanner



> -----Ursprüngliche Nachricht-----
> Von:	rjent@rjent.pair.com [SMTP:rjent@rjent.pair.com]
> Gesendet am:	Donnerstag, 14. Oktober 1999 02:25
> An:	vtcl@neuron.com
> Betreff:	[vtcl] Using $widget(alias) calls in procs?
> 
> Greetings,
> 
> I am waniting to use the $widget(alias) feature in procs but seem to be
> having a bit of trouble understanding the global / local concept in this
> specific case.
> 
> I have tried:
> 
> global alias
> 
> inside the proc with no success.  Thinking that the alias is a global var.
> 
> Until I can find a better solution I am just passing $widget(alias) to the
> procs, which works fine, but, seems a bit cLuMbsY.
> 
> Thoughts welcome!
> 
> -- RJ Ent. --
> http://www.rjent.pair.com  Had Enough GPF's from M$? 
> Try something stable:  http://www.freebsd.org or http://www.redhat.com
> Strong Supporter of Visual Tcl -- http://www.neuron.com/stewart/vtcl/
> 
> --------------------------------------------------------------------------
> -
> To unsubscribe from the Visual Tcl mailing list, please send a message
> to majordomo@neuron.com with "unsubscribe vtcl you@your.address" in the
> message body (where you@your.address is your e-mail address).
---------------------------------------------------------------------------
To unsubscribe from the Visual Tcl mailing list, please send a message
to majordomo@neuron.com with "unsubscribe vtcl you@your.address" in the
message body (where you@your.address is your e-mail address).

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic