From: Hidetoshi NAGAI Date: 2006-04-24T19:01:17+09:00 Subject: Re: how to integrate ruby tk/gtk event loop with another kind event loop such as socket server? Maybe, the followings are not answers which you want. Tcl/Tk libraries with One-Click Ruby Installer 182-15 is only standard libraries of Tcl/Tk. Perl/Tk uses the 'ptk' library which includes some mega widgets from some Tcl/Tk extensions. Ruby/Tk supports such extensions by libraries on "tkextlib/*". But, to use such extionstions, those are available on Tcl/Tk. I recommend you to get ActiveTcl binary package from ActiveState site (http://www.activestate.com/), and use One-Click Ruby Installer 184-16 rc1. ActiveTcl binary package inlcudes much extensions than 'ptk'. Of course, it includes some extensions with a notebook widget. # Current latest release of Tcl/Tk is 8.4.13. # Although I don't test it yet, probably, it will work with Ruby/Tk. # In the near future, I'll check the changes between 8.4.12 and # 8.4.13, and new features included in ActiveTcl8.5.0.0 Beta5. # Before commiting supports for such changes, you may need # Tk.tk_call() method to use new features. By the way, I cannot understand the following part of your mail. From: "Talha Oktay" Subject: how to integrate ruby tk/gtk event loop with another kind event loop such as socket server? Date: Mon, 24 Apr 2006 17:40:02 +0900 Message-ID: > I have also noticed that some of the other features such > as binding external events and geometry managers except pack manager that > are available in perl tk are not available in ruby binding. I think those are supported on Ruby/Tk. Please tell me the case which you have troubles. Did you see the Ruby/Tk examples on Ruby source tree? Those are also included in One-Click Ruby Installer. > Besides I > could not find a way to integrate an external event loop or process to Tk > eventloop. There are some explanations about filevent and tk send interface > which iseemed not available in windows and in ruby. Old Ruby/Tk had some troubles when running an eventloop on non-main thread. But current Ruby/Tk is safe for Ruby's threads. There is no problem, even if an eventloop works on non-main thread or the other threads controll the Tk interpreter. So, it is better to create a thread for I/O operations. However, on Windows, I heard that there are some I/O operations blocks thread-switching. # That is the reason of why the sample 'irbtk.rb' ('wish'-like(?) IRB) # doesn't work properly on Windows. Do you say about such case? -- Hidetoshi NAGAI (nagai@ai.kyutech.ac.jp)