Ruby 之 Tk 创建新窗口

#!/usr/bin/env ruby

require 'tk'
hello = TkRoot.new
TkLabel.new( hello ) do
    text "\n  Hello, myValue!  \n"
    pack
end
Tk.mainloop

编程技巧