Forum: Ruby-Gnome 2 Switching off 'abstract class'-switch in Gtk::Container

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.
97b082da2e737a0d1c74e629f4f81b3b?d=identicon&s=25 Martin Nordholts (Guest)
on 2007-02-27 07:23
(Received via mailing list)
Hello,

I am implementing a custom ToolBox-container that is based on the code
from the Glade interface designer.

  class ToolBox < Gtk::Container
    # ...
  end

When I try to instantiate the class however, I get an 'abstract class
(TypeError)' error. Obviously this 'abstract class'-flag is internal to
GTK+ since abstract classes are not part of the Ruby-language.

So my question is, how do I properly switch this 'abstract class' flag
off in my ToolBox? Could this be a bug so that the best thing to do is
to try finding it in Ruby-GNOME2?



- Martin Nordholts


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share
your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p...
7585ed50675c4febe7619f25b44f7fe0?d=identicon&s=25 Markus Koller (Guest)
on 2007-02-27 19:07
(Received via mailing list)
On Tue, Feb 27, 2007 at 07:22:14AM +0100, Martin Nordholts wrote:
>   class ToolBox < Gtk::Container
>     # ...
>   end
>
> When I try to instantiate the class however, I get an 'abstract class
> (TypeError)' error. Obviously this 'abstract class'-flag is internal to
> GTK+ since abstract classes are not part of the Ruby-language.

Do you have a call to type_register in your class definition?


Cheers,
Markus

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share
your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p...
97b082da2e737a0d1c74e629f4f81b3b?d=identicon&s=25 Martin Nordholts (Guest)
on 2007-02-27 21:17
(Received via mailing list)
Aha

Thanks, that fixed that problem.

- Martin

tis 2007-02-27 klockan 19:06 +0100 skrev Markus Koller:
>
> ruby-gnome2-devel-en mailing list
> ruby-gnome2-devel-en@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/ruby-...


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share
your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p...
This topic is locked and can not be replied to.