Re: [gtkmm] Glade-2, libgtkmm, Xml::create, callbacks
- From: Douglas Roberts <dzzr lanl gov>
- To: Christer Palm <palm nogui se>
- Cc: Gtkmm List <gtkmm-list gnome org>
- Subject: Re: [gtkmm] Glade-2, libgtkmm, Xml::create, callbacks
- Date: Wed, 03 Sep 2003 11:01:45 -0600
Hi, Crister:
Christer Palm wrote:
Hi Douglas!
Douglas Roberts wrote:
I do believe a widget/object lookup tool should be provided by
glade/libglade/libglademm/libxml/whatever which provides similar
functionality to that provided by lookup_widget when glade is used to
produce C code.
It is a fact that GUI components often need to interact; therefore a
lookup tool is required.
The get_widget() method is what you are looking for. It is the
libglademm equivalent to the glade_xml_get_widget() function in
libglade. You should really have a closer look at the libglademm
documentation and examples.
Actually using get_widget is what got me started on this thread. From
the basic example in the examples directory of libglademm-2.0.1:
#include <libglademm/xml.h>
#include <gtkmm.h>
#include <iostream>
int main (int argc, char **argv)
{
Gtk::Main kit(argc, argv);
//Load the Glade file and instiate its widgets:
Glib::RefPtr<Gnome::Glade::Xml> refXml;
try
{
refXml = Gnome::Glade::Xml::create("basic.glade");
}
catch(const Gnome::Glade::XmlError& ex)
{
std::cerr << ex.what() << std::endl;
return 1;
}
.
.
.
The problem is that the callback functions defined by glade, and
declared in the "app_name".glade file are ignored when you instantiate
your gui application via Glib::RefPtr<Gnome::Glade::Xml> refXml;
--Doug
--
Christer Palm
--
===============================================================
Douglas Roberts, CCS-5 | "He has no enemies, but is
Los Alamos National Laboratory | intensely disliked by his
^ | friends."
(505)-667-4569 |
dzzr lanl gov | - Oscar Wilde
===============================================================
- References:
- [gtkmm] Glade-2, libgtkmm, Xml::create, callbacks
- Re: [gtkmm] Glade-2, libgtkmm, Xml::create, callbacks
- Re: [gtkmm] Glade-2, libgtkmm, Xml::create, callbacks
- Re: [gtkmm] Glade-2, libgtkmm, Xml::create, callbacks
- Re: [gtkmm] Glade-2, libgtkmm, Xml::create, callbacks
- Re: [gtkmm] Glade-2, libgtkmm, Xml::create, callbacks
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]