summaryrefslogtreecommitdiffstats
path: root/qtruby/rubylib/tutorial/t1/t1.rb
diff options
context:
space:
mode:
Diffstat (limited to 'qtruby/rubylib/tutorial/t1/t1.rb')
-rwxr-xr-xqtruby/rubylib/tutorial/t1/t1.rb11
1 files changed, 11 insertions, 0 deletions
diff --git a/qtruby/rubylib/tutorial/t1/t1.rb b/qtruby/rubylib/tutorial/t1/t1.rb
new file mode 100755
index 00000000..19d8a029
--- /dev/null
+++ b/qtruby/rubylib/tutorial/t1/t1.rb
@@ -0,0 +1,11 @@
+#!/usr/bin/env ruby
+$VERBOSE = true; $:.unshift File.dirname($0)
+
+require 'Qt'
+
+a = Qt::Application.new(ARGV)
+hello = Qt::PushButton.new('Hello World!', nil)
+hello.resize(100, 30)
+a.setMainWidget(hello)
+hello.show()
+a.exec()