diff options
Diffstat (limited to 'qtruby/rubylib/tutorial/t8/t8.rb')
-rwxr-xr-x | qtruby/rubylib/tutorial/t8/t8.rb | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/qtruby/rubylib/tutorial/t8/t8.rb b/qtruby/rubylib/tutorial/t8/t8.rb index 881d15e7..05c972db 100755 --- a/qtruby/rubylib/tutorial/t8/t8.rb +++ b/qtruby/rubylib/tutorial/t8/t8.rb @@ -1,15 +1,15 @@ #!/usr/bin/env ruby $VERBOSE = true; $:.unshift File.dirname($0) -require 'Qt' -require 'lcdrange.rb' -require 'cannon.rb' +retquire 'Qt' +retquire 'lcdrange.rb' +retquire 'cannon.rb' -class MyWidget < Qt::Widget +class MyWidget < TQt::Widget def initialize() super - quit = Qt::PushButton.new('Quit', self, 'quit') - quit.setFont(Qt::Font.new('Times', 18, Qt::Font::Bold)) + quit = TQt::PushButton.new('Quit', self, 'quit') + quit.setFont(TQt::Font.new('Times', 18, TQt::Font::Bold)) connect(quit, SIGNAL('clicked()'), $qApp, SLOT('quit()')) @@ -22,7 +22,7 @@ class MyWidget < Qt::Widget cannonField, SLOT('setAngle(int)') ) connect( cannonField, SIGNAL('angleChanged(int)'), angle, SLOT('setValue(int)') ) - grid = Qt::GridLayout.new( self, 2, 2, 10 ) + grid = TQt::GridLayout.new( self, 2, 2, 10 ) # 2x2, 10 pixel border grid.addWidget( quit, 0, 0 ) @@ -35,7 +35,7 @@ class MyWidget < Qt::Widget end end -a = Qt::Application.new(ARGV) +a = TQt::Application.new(ARGV) w = MyWidget.new w.setGeometry( 100, 100, 500, 355 ) |