On Wed, 2010-03-03 at 21:56 +0100, Andreas Volz wrote:
> Hello,
>
> I've created a Gtk::Menu (GTKMenu) with Glade. In my project I try to
> load it with libglademm:
>
> Gtk::Menu *mUmlEditMenu;
> mXMLGlade->get_widget ("umlEditMenu", mUmlEditMenu);
>
> The result is:
>
> (state:7484): libglademm-CRITICAL **: widget `umlEditMenu' not found in
> glade file `/home/andreas/src/svn/state/trunk/src/state.glade'
>
> ** (state:7484): CRITICAL **: Gnome::Glade::Xml::get_widget():
> dynamic_cast<> failed.
>
>
> And yes the object exist. Look here in the state.glade:
>
> <widget class="GtkMenu" id="umlEditMenu">
> <property name="visible">True</property>
> <child>
> <widget class="GtkImageMenuItem" id="umlEditDel">
> <property name="visible">True</property>
> <property name="label" translatable="yes">gtk-delete</property>
> <property name="use_underline">True</property>
> <property name="use_stock">True</property>
> </widget>
> </child>
> </widget>
>
> Has anyone an idea why it's not working?
>
> My last option would be to construct the Gtk::Menu without glade. :-(
>
I don't exactly know what are you doing or using, but there is one
possibilty - you are using Glade to create GUI and save a result in
GtkBuilder .xml format (which is now a default), which is probably
incompatible with libglade .xml format and now you are trying to load
GtkBuilder using libglade. See one of two solutions:
1. Continue using libglade, but edit your glade .xml file in Glade and
try to save it in Glade format.
2. Switch from libglade to GtkBuilder - libglade is deprecated anyway.
GtkBuilder is wrapped in gtkmm.
> regards
> Andreas
Hope this helps,
Krzesimir.
_______________________________________________
gtkmm-list mailing list
[email protected]
http://mail.gnome.org/mailman/listinfo/gtkmm-list