Hi, From: Nicolas Decoster <nicolas.decoster / noveltis.fr> Subject: widget modifs after calls to Tk.mainloop Date: Wed, 1 Sep 2004 00:00:56 +0900 Message-ID: <41349259.6080307 / noveltis.fr> > Is it possible using Ruby/Tk to create widgets, then view and > interactivly interact with them, then change their behavior and view and > interact again with them. For example in Tcl/Tk shell (wish): (snip) > Is there a similar command sequence for Ruby/Tk. For example, $ /usr/local/bin/irb irb(main):001:0> require 'tk' irb(main):002:0> Thread.new{Tk.mainloop} irb(main):003:0> v = 1 irb(main):004:0> b = TkButton.new(:command=>proc{puts v}).pack irb(main):005:0> v = 2 irb(main):006:0> b.command{puts "#{v}#{v}"} -- Hidetoshi NAGAI (nagai / ai.kyutech.ac.jp)