From mboxrd@z Thu Jan 1 00:00:00 1970 From: Lucio De Re To: 9fans@cse.psu.edu Subject: Re: [9fans] Limbo Tk FAQ? Message-ID: <20010525144239.R21254@cackle.proxima.alt.za> References: <20010525120255.399BF199ED@mail.cse.psu.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii In-Reply-To: <20010525120255.399BF199ED@mail.cse.psu.edu>; from rog@vitanuova.com on Fri, May 25, 2001 at 01:10:55PM +0100 Date: Fri, 25 May 2001 14:42:40 +0200 Topicbox-Message-UUID: a83017b6-eac9-11e9-9e20-41e7f4b1d025 On Fri, May 25, 2001 at 01:10:55PM +0100, rog@vitanuova.com wrote: > > i added a loadable module for the inferno shell to give shell access to > tk; this also includes channels (as they're an inextricable part of the > inferno tk interface). > The inferno shell is an utter treat. > the only part not familiar from rc is the ${...} notation which yields > the result of a loadable-module-defined command (sort of like `{...} > but without the uncertainty of the usual stdout tokenization) > If I buy the manual set now, do I get a discount when I eventually get to subscribe for the source licence? > once you've defined a function to execute tk commands: > > fn x { > tk $wid $* > } > Is there a plumber module, too? Or should the "fn" syntax be enhanced as for traps? > one can execute tk commands quite simply: > > x button .b -text {Hello world} -command {send cmd hello, world} > x pack .b > x update > chan cmd > tk namechan $wid cmd > while {} { > echo ${recv cmd} > } > > i guess this feels somewhat like tcl; it's certainly nice for hacking > up simple graphical interfaces to shell commands. All you're omitting is the upvar/uplevel capability to handle call by reference. We can't be far from the real thing :-) ++L