Text Editor using the Shooes toolkit isnt workig .?
i was going through many ruby books and found this amazing text editing code (its just 17 lines ) provided u use Shoes toolkit.
The code is working fine with no errors . but its only able to read (open) and input file but not save the text u wrote in the text box into a file.
Shoes.app(:width => 600, :height => 500) do
@open_button = button "Open"
@save_button = button "Save"
@t = edit_box :width => 0.9, :height => 400
@t.text = File.read(ask_open_file)
File.new(ask_save_file, 'w') do |f|