I built a Windows GUI using DialogBlocks v4.29, saved the resulting XRC
for processing with wxRuby’s xrciser tool.
Following Ruby products installed:
wxRuby is v 2.0.0
wxSugar is v0.1.22
Ruby is v1.9.1
Rubygems is v1.3.1
Running xrciser on the file gives the following:
C:\ruby>xrcise -o toolgui.rb tool.xrc
c:/ruby/lib/ruby/gems/1.9.1/gems/wx_sugar-0.1.22/lib/wx_sugar/xrc/outputter.rb:4
6:in clean_id_attr_readers': undefined method
each’ for
#String:0xe7cdf8 (No
MethodError)
from (erb):16:in output' from c:/ruby/lib/ruby/1.9.1/erb.rb:753:in
eval’
from c:/ruby/lib/ruby/1.9.1/erb.rb:753:in result' from c:/ruby/lib/ruby/gems/1.9.1/gems/wx_sugar-0.1.22/lib/wx_sugar/xrc/o utputter.rb:19:in
output’
from
c:/ruby/lib/ruby/gems/1.9.1/gems/wx_sugar-0.1.22/bin/xrcise:126:in
block (2 levels) in <top (required)>' from c:/ruby/lib/ruby/gems/1.9.1/gems/wx_sugar-0.1.22/bin/xrcise:125:in
each’
from
c:/ruby/lib/ruby/gems/1.9.1/gems/wx_sugar-0.1.22/bin/xrcise:125:in
block in <top (required)>' from c:/ruby/lib/ruby/gems/1.9.1/gems/wx_sugar-0.1.22/bin/xrcise:124:in
open’
from
c:/ruby/lib/ruby/gems/1.9.1/gems/wx_sugar-0.1.22/bin/xrcise:124:in
<top (required)>' from c:/ruby/bin/xrcise:19:in
load’
from c:/ruby/bin/xrcise:19:in `’
Checked the outputter source; can’t understand why “each” is not a
method for “str” here so tried debugging – got an error saying
ruby-debug not working with Ruby 1.9.1 yet.
Any clues as to what is going on? Here is the xrc:
<?xml version="1.0" encoding="UTF-8"?> wxDEFAULT_FRAME_STYLE|wxCAPTION|wxCLOSE_BOX|wxTAB_TRAVERSAL #b1bdd1 590,612 Tool 1 wxVERTICAL wxGROW 5 2 wxHORIZONTAL wxALIGN_TOP 5 1 0,1 0,1 0 0 10,20 wxGROW|wxGROW 5 0,0 1,2 wxVERTICAL wxGROW|wxALL 5 1 Instructions wxALIGN_LEFT Step 1 wxGROW|wxGROW 5 1,0 1,3 wxVERTICAL wxGROW|wxALL 5 3 Choose Spreadsheet wxFLP_DEFAULT_STYLE C:\\ruby\\tool.xrc Select a file *.* wxALIGN_LEFT|wxALIGN_TOP 5 0,2 1,1 wxVERTICAL wxALIGN_LEFT|wxALL 5 Select wxRA_SPECIFY_COLS Choose 1 0 A B C D wxGROW|wxGROW|wxALL 5 0,2 1,1 wxHW_SCROLLBAR_NEVER 1 wxALIGN_CENTER_HORIZONTAL|wxTOP|wxBOTTOM 5 wxHORIZONTAL wxALIGN_TOP|wxALL 5 Select wxRA_SPECIFY_COLS Action 1 0 1 2 wxALIGN_CENTER_VERTICAL|wxALL 5 Go wxALIGN_CENTER_VERTICAL|wxALL 5 Done wxGROW|wxALL 5 Progress wxGA_HORIZONTAL|wxGA_SMOOTH 0 100 wxGROW|wxALL 5 1