From alex at pressure.to Fri Apr 1 06:01:58 2005 From: alex at pressure.to (Alex Fenton) Date: Fri Apr 1 05:57:01 2005 Subject: [Wxruby-users] MDI on OS X Message-ID: <424D2A26.40408@pressure.to> Hi I was wondering if the mdi sample runs for anyone on OS X? On 10.3, in both wxruby and wxruby-swig it creates a ruby app but doesn't show any child windows on request. cheers alex From dalegard at gmail.com Sun Apr 3 22:41:19 2005 From: dalegard at gmail.com (David Legard) Date: Sun Apr 3 22:36:04 2005 Subject: [Wxruby-users] BusyCursor probs in 0.6 In-Reply-To: <200504011057.j31AvMdS009865@rubyforge.org> References: <200504011057.j31AvMdS009865@rubyforge.org> Message-ID: <85fdb3b305040319415b60e8ec@mail.gmail.com> The new block version of BusyCursor doesn't work for me -- some actions in between the { braces } do not get carried out. To illustrate, I have taken the nothing.rbw sample app, and added a couple of lines to it, so the full code now reads: require 'wxruby' include Wx class MyFrame < Wx::Frame def initialize(title) super(nil, -1, title) end end class NothingApp < Wx::App def on_init frame = MyFrame.new("Minimal wxRuby App") frame.show BusyCursor.new { message_box("This is a control sample", "About Controls") } end end a = NothingApp.new a.main_loop() ----------------------- However, the message_box line is never executed and the program seems to hang. Could somebody advise if I am doing something wrong? Thanks, David L. From wxruby at qualitycode.com Mon Apr 4 10:31:14 2005 From: wxruby at qualitycode.com (Kevin Smith) Date: Mon Apr 4 10:26:17 2005 Subject: [Wxruby-users] BusyCursor probs in 0.6 In-Reply-To: <85fdb3b305040319415b60e8ec@mail.gmail.com> References: <200504011057.j31AvMdS009865@rubyforge.org> <85fdb3b305040319415b60e8ec@mail.gmail.com> Message-ID: <42514FB2.8030301@qualitycode.com> David Legard wrote: > class NothingApp < Wx::App > def on_init > frame = MyFrame.new("Minimal wxRuby App") > frame.show > BusyCursor.new { > message_box("This is a control sample", "About Controls") > } > > end > end > ----------------------- > However, the message_box line is never executed and the program seems > to hang. Could somebody advise if I am doing something wrong? The sequence of this code is unusual, and that might be causing the problems. You might either: 1. do the BusyCursor and message_box *before* creating the frame, or 2. put the BusyCursor around both the frame.show and the message_box, or 3. move the BusyCursor and message_box inside the MyFrame class Beyond that, it seems odd to try to have the busy cursor displayed while a modal dialog (message_box) is showing. A more "fair" test might be to put up the busy cursor, and then just sleep for 5 seconds to simulate some slow non-UI operation taking place. Unfortunately, I don't have time right now to actually test and research this. Hopefully these guesses will help, Kevin From devel at nicreations.com Mon Apr 4 17:13:59 2005 From: devel at nicreations.com (Nick) Date: Mon Apr 4 17:06:59 2005 Subject: [Wxruby-users] BusyCursor probs in 0.6 Message-ID: I believe the correct method is BusyCursor.busy, not BusyCursor.new > The new block version of BusyCursor doesn't work for me -- some > actions in between the { braces } do not get carried out. > > To illustrate, I have taken the nothing.rbw sample app, and added a > couple of lines to it, so the full code now reads: > > require 'wxruby' > include Wx > > class MyFrame < Wx::Frame > def initialize(title) > super(nil, -1, title) > end > end > > class NothingApp < Wx::App > def on_init > frame = MyFrame.new("Minimal wxRuby App") > frame.show > BusyCursor.new { > message_box("This is a control sample", "About Controls") > } > > end > end > > a = NothingApp.new > a.main_loop() > > ----------------------- > However, the message_box line is never executed and the program seems > to hang. Could somebody advise if I am doing something wrong? > > Thanks, > > David L. > _______________________________________________ > wxruby-users mailing list > wxruby-users@rubyforge.org > http://rubyforge.org/mailman/listinfo/wxruby-users > > -- From wxruby at qualitycode.com Mon Apr 4 21:32:27 2005 From: wxruby at qualitycode.com (Kevin Smith) Date: Mon Apr 4 21:27:18 2005 Subject: [Wxruby-users] BusyCursor probs in 0.6 In-Reply-To: References: Message-ID: <4251EAAB.9030707@qualitycode.com> Ah. That's an error prone interface. BusyCursor.new should either do the right thing, or be hidden as private, or raise an exception if called incorrectly. Kevin Nick wrote: > I believe the correct method is BusyCursor.busy, not BusyCursor.new > > >>The new block version of BusyCursor doesn't work for me -- some >>actions in between the { braces } do not get carried out. >> >>To illustrate, I have taken the nothing.rbw sample app, and added a >>couple of lines to it, so the full code now reads: >> >>require 'wxruby' >>include Wx >> >>class MyFrame < Wx::Frame >> def initialize(title) >> super(nil, -1, title) >> end >>end >> >>class NothingApp < Wx::App >> def on_init >> frame = MyFrame.new("Minimal wxRuby App") >> frame.show >> BusyCursor.new { >> message_box("This is a control sample", "About Controls") >> } >> >> end >>end >> >>a = NothingApp.new >>a.main_loop() >> >>----------------------- >>However, the message_box line is never executed and the program seems >>to hang. Could somebody advise if I am doing something wrong? >> >>Thanks, >> >>David L. >>_______________________________________________ >>wxruby-users mailing list >>wxruby-users@rubyforge.org >>http://rubyforge.org/mailman/listinfo/wxruby-users >> >> > > From devel at nicreations.com Mon Apr 4 23:56:51 2005 From: devel at nicreations.com (Nick) Date: Mon Apr 4 23:54:38 2005 Subject: [Wxruby-users] BusyCursor probs in 0.6 In-Reply-To: <4251EAAB.9030707@qualitycode.com> References: <4251EAAB.9030707@qualitycode.com> Message-ID: <42520C83.6010603@nicreations.com> When I saw the post I thought the same thing. I'll fix it after work cools off a little. Nick Kevin Smith wrote: > Ah. That's an error prone interface. BusyCursor.new should either do the > right thing, or be hidden as private, or raise an exception if called > incorrectly. > > Kevin > > > > Nick wrote: > >>I believe the correct method is BusyCursor.busy, not BusyCursor.new >> >> >> >>>The new block version of BusyCursor doesn't work for me -- some >>>actions in between the { braces } do not get carried out. >>> >>>To illustrate, I have taken the nothing.rbw sample app, and added a >>>couple of lines to it, so the full code now reads: >>> >>>require 'wxruby' >>>include Wx >>> >>>class MyFrame < Wx::Frame >>> def initialize(title) >>> super(nil, -1, title) >>> end >>>end >>> >>>class NothingApp < Wx::App >>> def on_init >>> frame = MyFrame.new("Minimal wxRuby App") >>> frame.show >>> BusyCursor.new { >>> message_box("This is a control sample", "About Controls") >>> } >>> >>> end >>>end >>> >>>a = NothingApp.new >>>a.main_loop() >>> >>>----------------------- >>>However, the message_box line is never executed and the program seems >>>to hang. Could somebody advise if I am doing something wrong? >>> >>>Thanks, >>> >>>David L. >>>_______________________________________________ >>>wxruby-users mailing list >>>wxruby-users@rubyforge.org >>>http://rubyforge.org/mailman/listinfo/wxruby-users >>> >>> >> >> > > _______________________________________________ > wxruby-users mailing list > wxruby-users@rubyforge.org > http://rubyforge.org/mailman/listinfo/wxruby-users > > > From dmiceman at ubiz.ru Wed Apr 27 06:26:06 2005 From: dmiceman at ubiz.ru (Dmitry Morozhnikov) Date: Wed Apr 27 06:20:08 2005 Subject: [Wxruby-users] does anyone have success with wxruby with wxwidgets 2.6? Message-ID: <593722075.20050427192606@ubiz.ru> Hello, All. I`m trying to compile wxruby with wxwidgets 2.6 under windows with latest mingw, but have lot of troubles. wxwidgets and ruby 1.8.2 compiles just fine, examples work pretty well. To make wxruby compile (non-swig, from cvs) i was made some minor changes like explicit cast ("IN2NUM(...)" to "INT2NUM((long) ...)"), removed some constant definitions from const.cpp (pens, brushes, colors), removed wxEntryInitGui() from app.cpp because as i see it is dropped from wxwidgets completely. After all, it compiles now. But just any ruby script causes it to segfault. From a gdb i see a lot of wxwidgets messages about invalid window handle when trying to run samples/minimal/minimal.rb: warning: 19:11:41: In file ../src/msw/frame.cpp at line 441: 'SetMenu' failed with error 0x00000578 (???????????? ?????????? ????.). warning: 19:11:41: In file ../include/wx/msw/private.h at line 335: 'GetClientRect' failed with error 0x00000578 (???????????? ?????????? ????.). warning: 19:11:41: In file ../src/msw/statbr95.cpp at line 185: 'StatusBar_SetParts' failed with error 0x00000578 (???????????? ?????????? ????.). (unreadable russian letters mean just -- "inappropriate window descriptor") When i`m trying to get HWND from ruby side with this code: require 'wxruby' class App < Wx::App def on_init frame = Wx::Frame.new nil, -1, 'test' puts frame.get_hwnd $stdout.flush end end App.new.main_loop I`m got: [src]$ ruby ../test.rbw 0 This application has requested the Runtime to terminate it in an unusual way. Please contact the application's support team for more information. ../test.rbw:11: [BUG] Segmentation fault ruby 1.8.2 (2005-04-25) [i386-mingw32] As far as i`m understand this, it is generally should not happens because there is no much api changes between 2.4 and 2.6, but.. Can anyone show me the way to fight this trouble? BTW: What is a correct way to debug ruby extensions under windows? With gdb i can`t get symbols on stack with 'bt' command, but everything -- ruby, wxwidgets, wxruby is compiled with -g. -- Dmitry mailto:dmiceman@ubiz.ru From wxruby at qualitycode.com Wed Apr 27 09:35:48 2005 From: wxruby at qualitycode.com (Kevin Smith) Date: Wed Apr 27 09:29:59 2005 Subject: [Wxruby-users] does anyone have success with wxruby with wxwidgets 2.6? In-Reply-To: <593722075.20050427192606@ubiz.ru> References: <593722075.20050427192606@ubiz.ru> Message-ID: <426F9534.2080106@qualitycode.com> Dmitry Morozhnikov wrote: > Hello, All. > > I`m trying to compile wxruby with wxwidgets 2.6 under windows with > latest mingw, but have lot of troubles. My guess is that wxwidgets 2.6 is not being properly initialized by wxruby. The code that performs the initialization is somewhat of a hack, relying on undocumented wxwindows 2.4 calls. It is quite possible that 2.6 must be initialized using different calls, or in a different order. In wxruby 0.6, this code is spread between WxApp::Init, wxAppWithCallbacks::MainLoop, and the Init_wxruby() function in wx.cpp. In wxruby-swig, the initialization is simpler, and can be seen in swig/classes/App.i in main_loop. In fact, this code *might* just work with 2.6 as-is, but I don't think anyone has tried it. There would probably be other parts of wxruby-swig that would need to change, which is also true with wxruby-0.6. Kevin From dmiceman at ubiz.ru Wed Apr 27 12:10:45 2005 From: dmiceman at ubiz.ru (Dmitry Morozhnikov) Date: Wed Apr 27 12:09:12 2005 Subject: [Wxruby-users] does anyone have success with wxruby with wxwidgets 2.6? In-Reply-To: <426F9534.2080106@qualitycode.com> References: <593722075.20050427192606@ubiz.ru> <426F9534.2080106@qualitycode.com> Message-ID: <1811299783.20050428011045@ubiz.ru> Hello, Kevin. You wrote 27.04.2005, 22:35:48: Thank you for reply. You pointed me to the right place! :-) Well.. There is a patch attached which allow me to compile wxruby and run samples/minimal/minimal.rb Main thing is to call wxAppWithCallbacks::Initialize() manually. But! It is not state of the art patch, it is just an ugly hack because i still does not understand wxwidgets initialization procedures. I just found a place where window classes being registered and call it. -- Dmitry mailto:dmiceman@ubiz.ru -------------- next part -------------- A non-text attachment was scrubbed... Name: wxwidgets-2.6.diff Type: application/octet-stream Size: 9833 bytes Desc: not available Url : http://rubyforge.org/pipermail/wxruby-users/attachments/20050428/5fa44022/wxwidgets-2.6-0001.obj From devel at nicreations.com Wed Apr 27 22:08:36 2005 From: devel at nicreations.com (Nick) Date: Wed Apr 27 22:05:46 2005 Subject: [Wxruby-users] does anyone have success with wxruby with wxwidgets 2.6? In-Reply-To: <1811299783.20050428011045@ubiz.ru> References: <593722075.20050427192606@ubiz.ru> <426F9534.2080106@qualitycode.com> <1811299783.20050428011045@ubiz.ru> Message-ID: <427045A4.3050103@nicreations.com> Thanks for the patch. I will apply it as soon as I can. Right now the plan is to have wxruby-swig support next gen wxWidgets, and let the old codebase support wxWidgets 2.4. Nick Dmitry Morozhnikov wrote: > Hello, Kevin. > > You wrote 27.04.2005, 22:35:48: > > Thank you for reply. You pointed me to the right place! :-) > > Well.. There is a patch attached which allow me to compile wxruby and > run samples/minimal/minimal.rb > > Main thing is to call wxAppWithCallbacks::Initialize() manually. > > But! It is not state of the art patch, it is just an ugly hack because > i still does not understand wxwidgets initialization procedures. I > just found a place where window classes being registered and call it. > > > > ------------------------------------------------------------------------ > > _______________________________________________ > wxruby-users mailing list > wxruby-users@rubyforge.org > http://rubyforge.org/mailman/listinfo/wxruby-users From joaopedrosa at gmail.com Wed Apr 27 22:17:52 2005 From: joaopedrosa at gmail.com (Joao Pedrosa) Date: Wed Apr 27 22:11:51 2005 Subject: [Wxruby-users] does anyone have success with wxruby with wxwidgets 2.6? In-Reply-To: <427045A4.3050103@nicreations.com> References: <593722075.20050427192606@ubiz.ru> <426F9534.2080106@qualitycode.com> <1811299783.20050428011045@ubiz.ru> <427045A4.3050103@nicreations.com> Message-ID: Hi, On 4/27/05, Nick wrote: > > Thanks for the patch. I will apply it as soon as I can. > > Right now the plan is to have wxruby-swig support next gen wxWidgets, > and let the old codebase support wxWidgets 2.4. That's cool. I'm anxiously waiting to test the new version. I've started experimenting with wxRuby and I like what I see. Thanks for it. Cheers, Joao From dmiceman at ubiz.ru Thu Apr 28 07:14:07 2005 From: dmiceman at ubiz.ru (Dmitry Morozhnikov) Date: Thu Apr 28 07:14:44 2005 Subject: [Wxruby-users] does anyone have success with wxruby with wxwidgets 2.6? In-Reply-To: <427045A4.3050103@nicreations.com> References: <593722075.20050427192606@ubiz.ru> <426F9534.2080106@qualitycode.com> <1811299783.20050428011045@ubiz.ru> <427045A4.3050103@nicreations.com> Message-ID: <31232407.20050428201407@ubiz.ru> Hello, Nick. You wrote 28.04.2005, 11:08:36: N> Thanks for the patch. I will apply it as soon as I can. Thank you! :-) But please use new patch (attached). At least, it returns back default colors, pens and brushes (i`m divide constants initialization into two parts, second part is called after wxApp::Initialize()). I`m test this version of wxruby with my own app which is complex enough and all looks fine for me. N> Right now the plan is to have wxruby-swig support next gen wxWidgets, N> and let the old codebase support wxWidgets 2.4. Hmm.. Can`t agree with you :-) What is advantages of using SWIG to create wrappers? I found what SWIG is too complex, too complicated and absolutely unnecessary to use it. Plain wxruby is a best demonstration of that :-) Anyway, may be it is possible to label wxruby 0.6 as a last version for wxwidgets 2.4 and go further? -- Dmitry mailto:dmiceman@ubiz.ru -------------- next part -------------- A non-text attachment was scrubbed... Name: wxwidgets-2.6-2.diff Type: application/octet-stream Size: 12368 bytes Desc: not available Url : http://rubyforge.org/pipermail/wxruby-users/attachments/20050428/e7a0bc63/wxwidgets-2.6-2.obj From wxruby at qualitycode.com Thu Apr 28 10:05:45 2005 From: wxruby at qualitycode.com (Kevin Smith) Date: Thu Apr 28 09:59:52 2005 Subject: [Wxruby-users] does anyone have success with wxruby with wxwidgets 2.6? In-Reply-To: <31232407.20050428201407@ubiz.ru> References: <593722075.20050427192606@ubiz.ru> <426F9534.2080106@qualitycode.com> <1811299783.20050428011045@ubiz.ru> <427045A4.3050103@nicreations.com> <31232407.20050428201407@ubiz.ru> Message-ID: <4270EDB9.6070808@qualitycode.com> Dmitry Morozhnikov wrote: > What is advantages of using SWIG to create wrappers? I found what SWIG > is too complex, too complicated and absolutely unnecessary to use it. > Plain wxruby is a best demonstration of that :-) I was the maintainer of wxruby for a while, and initiated the move to swig. Originally I also thought that swig was too complicated, and I didn't want to use it. But after actually working with it, I see that it really is much easier than other approaches. Not only is it much easier to support additional classes and methods using swig, but it is also far easier to support global features like clean memory management, and the ability to subclass C++ classes in Ruby, and to have proper callbacks. In my opinion, wxruby-swig is far superior to the older wxruby code. I believe if the goal is a top-notch wxruby, it will be much easier and faster to get there using wxruby-swig. However, if you want to improve the older wxruby code, I can't imagine anyone complaining. Kevin From wxruby at qualitycode.com Thu Apr 28 10:08:30 2005 From: wxruby at qualitycode.com (Kevin Smith) Date: Thu Apr 28 10:02:35 2005 Subject: [Wxruby-users] wxWidgets 2.6.0 has been released Message-ID: <4270EE5E.7040301@qualitycode.com> In case you haven't seen the announcement: wxWidgets 2.6.0 is the new stable release of the wx toolkit. http://wxwidgets.org Kevin From usrlocalinfo at yahoo.com Sat Apr 30 04:35:01 2005 From: usrlocalinfo at yahoo.com (DJB) Date: Sat Apr 30 15:10:55 2005 Subject: [Wxruby-users] wxRuby Roadmap, Schedule and wxWidgets 2.6.0 Message-ID: Hi, I'm very interested in migrating some apps to ruby and wxRuby. Is there a rough estimate of when wxRuby will support wxWidgets 2.6.0? Are there specific tasks that require volunteers?