Forum: Ruby-Gnome 2 Can't Override Widget class in Gtk3

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
0d130f179f85401f248e6ebc2ef8292f?d=identicon&s=25 Eric C. (eric_c)
on 2016-05-04 01:33
Hi:

I'm working on an upgrade to visualruby that uses gtk3!

However, I've run into a few problems.

In my first version of visualruby, I added to the Gtk::Widget class:

Module Gtk

  class Widget
        ....
  end
end

Howver, with gtk 3 I get this error/warning, and the class is not
loaded:

/home/eric/.rvm/gems/ruby-2.3.0/gems/gobject-introspection-3.0.8/lib/gobject-introspection/loader.rb:233:
warning: already initialized constant Gtk::Widget
/home/eric/.rvm/gems/ruby-2.3.0/gems/vrlib-3.0.0/lib/Widget.rb:3:
warning: previous definition of Widget was here

How do I override the Widget class?

Thanks for all your great work!

Eric
This topic is locked and can not be replied to.