I''m using wx_sugar 0.1.2 with wxruby2-preview 0.0.37 on OSX and am coming up with a strange error when trying to create a SpinCtrl: class DatePicker < Wx::Dialog def initialize super(nil, :title => "Pick a date...") arrange_vertically(:padding => 5) @month = Wx::SpinCtrl.new(self) # line 19 add(@month) end end gives error: ArgumentError: Error initializing # Sent paramters: [#, -1, #, #, 4, -1, #, #, 4096, 0, 100, 0] correct parameters are: id (Fixnum) pos (Wxruby2::Point) size (Wxruby2::Size) style (Fixnum) id (Fixnum) pos (Wxruby2::Point) size (Wxruby2::Size) style (Fixnum) min (Fixnum) max (Fixnum) initial (Fixnum) method initialize in keyword_constructors.rb at line 246 method initialize in date_picker.rb at line 19 method initialize in main_window.rb at line 9 method listen in event_connector.rb at line 125 at top level in - at line 16 Ruby version: ruby 1.8.4 (2005-12-24) [powerpc-darwin8.7.0] The SpinCtrl is working fine in the e.g. Big Demo, and other types of controls can be added in this particular dialog fine. Anyone got any ideas as to what might be going wrong? Thanks, Alex Speller
Hi Alex Speller wrote:> I''m using wx_sugar 0.1.2 with wxruby2-preview 0.0.37 on OSX and am > coming up with a strange error when trying to create a SpinCtrl: > >...> ArgumentError: Error initializing # Sent paramters: [#, -1, #, #, 4, > -1, #, #, 4096, 0, 100, 0] correct parameters are: id (Fixnum) pos > (Wxruby2::Point) size (Wxruby2::Size) style (Fixnum) id (Fixnum) pos > (Wxruby2::Point) size (Wxruby2::Size) style (Fixnum) min (Fixnum) max > (Fixnum) initial (Fixnum)Think this is a same/similar bug in keyword_classes.rb - can you please try with recently released 0.1.3? thanks alex
> Alex Speller wrote: >> I''m using wx_sugar 0.1.2 with wxruby2-preview 0.0.37 on OSX and am >> coming up with a strange error when trying to create a SpinCtrl: >> >> > ... >> ArgumentError: Error initializing # Sent paramters: [#, -1, #, #, 4, >> -1, #, #, 4096, 0, 100, 0] correct parameters are: id (Fixnum) pos >> (Wxruby2::Point) size (Wxruby2::Size) style (Fixnum) id (Fixnum) pos >> (Wxruby2::Point) size (Wxruby2::Size) style (Fixnum) min (Fixnum) max >> (Fixnum) initial (Fixnum) > Think this is a same/similar bug in keyword_classes.rb - can you > please > try with recently released 0.1.3?Problem with mailing list (or my email maybe)... Posted this before I posted the original one you responded, and it didn''t come through so I posted again. Then this one came through 4 days later - odd. It was solved by your original fix, I''m just about to download 0.1.3 and check that over. Cheers, Alex