diff options
Diffstat (limited to 'ext/tk/sample/tkhello.rb')
-rw-r--r-- | ext/tk/sample/tkhello.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/ext/tk/sample/tkhello.rb b/ext/tk/sample/tkhello.rb new file mode 100644 index 0000000000..5188fe1c8c --- /dev/null +++ b/ext/tk/sample/tkhello.rb @@ -0,0 +1,10 @@ +require "tk" + +TkButton.new(nil, + 'text' => 'hello', + 'command' => proc{print "hello\n"}).pack('fill'=>'x') +TkButton.new(nil, + 'text' => 'quit', + 'command' => 'exit').pack('fill'=>'x') + +Tk.mainloop |