I''ve checked a number of new .i files into the wxruby-swig tree. Not all of them are fully tested, but I thought it would be better for them to be there than to have somebody start duplicating the work. I''ve also added the ''caret'' and ''image'' samples, as well as the generic etc/test.rb. These need the unreleased SWIG-1.3.22. The current release candidate has a bug that has been addressed. I hope this weekend to document the process to adding a .i file to the source, as there are a number of gotchas to work around SWIG issues. The current biggie is that there is a bug with directors and polymorphic constructors. I need to make a test case for Lyle to demonstrate it, but it wreaks havoc on wxWidgets. I''m using the wxruby samples as test cases for wxruby swig. The latest accomplishment is that the Dialogs sample loads and one or two of the dialogs even work too. A number of issues remain, including a race condition between wxWidgets and the Ruby GC on Window cleanup, and making all the classes as ruby friendly as they''ve become in wxruby.
Nick wrote:> > I''ve checked a number of new .i files into the wxruby-swig tree.Excellent!> there are a number of > gotchas to work around SWIG issues. The current biggie is that there is > a bug with directors and polymorphic constructors. I need to make a test > case for Lyle to demonstrate it, but it wreaks havoc on wxWidgets.Yes. I frequently told swig to ignore all but one of the overloaded constructors to avoid errors. I believe the problem is that swig is adding its own parameter to the *end* of the signature. I think if it always inserted this special extra parameter as the *first* parameter, things would be great. That''s a swig change that I might be able to take on. If I''m not having to create .i files and samples, I can focus on the deeper, dirtier stuff like that.> dialogs even work too. A number of issues remain, including a race > condition between wxWidgets and the Ruby GC on Window cleanup,I don''t think I''ve seen that one. Is it intermittent? Is it only a problem under MS-Windows? Can you force it by initiating GC operations at certain times?> making all the classes as ruby friendly as they''ve become in wxruby.Yes, that''s important. Kevin
Take the following code: t1 = Wx::TextCtrl.new( @panel , -1 , "text1" ) puts t1.get_size.get_height # outputs 21 t3 = Wx::TextCtrl.new( @panel , -1 , "text3" ) t3.set_font( Wx::Font.new( 15 , Wx::DEFAULT , Wx::NORMAL , Wx::BOLD ) ) puts t3.get_size.get_height # outputs 21 When you display the textctrl on the screen it only sizes the textctrl field with a height of 21 pixels for each TextCtrl field. I cannot read half of the text in the t3 textctrl field. Is this a bug ? Zach