Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!aioe.org!feeder.news-service.com!de-l.enfer-du-nord.net!feeder2.enfer-du-nord.net!talisker.lacave.net!lacave.net!not-for-mail From: Juju SL Newsgroups: comp.lang.ruby Subject: Tk : non blocking Tk.mainloop Date: Wed, 13 Apr 2011 12:20:37 -0500 Organization: Service de news de lacave.net Lines: 29 Message-ID: <58d66ab4de539ec84adb59d9fbde9312@ruby-forum.com> NNTP-Posting-Host: bristol.highgroove.com Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Trace: talisker.lacave.net 1302715265 5589 65.111.164.187 (13 Apr 2011 17:21:05 GMT) X-Complaints-To: abuse@lacave.net NNTP-Posting-Date: Wed, 13 Apr 2011 17:21:05 +0000 (UTC) X-Received-From: This message has been automatically forwarded from the ruby-talk mailing list by a gateway at comp.lang.ruby. If it is SPAM, it did not originate at comp.lang.ruby. Please report the original sender, and not us. Thanks! For more details about this gateway, please visit: http://blog.grayproductions.net/categories/the_gateway X-Mail-Count: 381444 X-Ml-Name: ruby-talk X-Rubymirror: Yes X-Ruby-Talk: <58d66ab4de539ec84adb59d9fbde9312@ruby-forum.com> Xref: x330-a1.tempe.blueboxinc.net comp.lang.ruby:2775 Hi all, I'm new in this forum (but I have been following it for months) I did some canvas tests on my Debian Squeeze with Ruby 1.8 + Tk, and everything was OK. Then I chose to move to Ruby 1.9 ; so I cleaned my old Ruby packages and installed "ruby1.9.1-full package", which comes with Tk8.4 My problem is I can't get Ruby TK programs run properly, because the Tk.mainloop is non blocking ; my program exists immediately, I only see the Tk canvas appear and disappear. This occurs even on the simpliest program, like : require 'tk' rr=TkRoot.new cc=TkCanvas.new(rr) cc.pack Tk.mainloop Running it under IRB, the window appears correctly. Any clue about this behaviour and how to make Tk.mainloop work as expected ? Thanks -- Posted via http://www.ruby-forum.com/.