If you have any questions about the call between glade and gtk, please help me !!

Source: Internet
Author: User
If you have any questions about the call between glade and gtk, please help me !! -- Linux general technology-Linux technology and application information. for details, refer to the following section. Gcc-o glade main. c 'pkg-config -- cflags -- libs gtk +-2.0 libglade-2.0'
The connection is passed and no error is reported. However, an error is reported when running./glade.
The prompt is:
(Glade: 14667): libglade-WARNING **: Expected . Got .
(Glade: 14667): libglade-WARNING **: did not finish in PARSER_FINISH state
(Glade: 14667): libglade-CRITICAL **: glade_xml_get_widget: assertion 'self! = NULL 'failed'
(Glade: 14667): GLib-GObject-CRITICAL **: g_object_unref: assertion 'G _ IS_OBJECT (object) 'failed
(Glade: 14667): Gtk-CRITICAL **: IA _ gtk_widget_show: assertion 'gtk _ IS_WIDGET (widget) 'failed
The main. c code is:
# Include
# Include
Int main (int argc, char * argv [])
{
GladeXML * gxml;
GtkWidget * window;
Gtk_init (& argc, & argv );
Gxml = glade_xml_new ("win. glade", NULL, NULL );
Window = glade_xml_get_widget (gxml, "window1 ");
G_object_unref (G_OBJECT (gxml ));
Gtk_widget_show (window );
Gtk_main ();
Return 0;
}

Here, win. glade is generated by glade in the format of gtkbulider. I drew only one window.
My gtk is 2.24.10 version, glade what version do not know, in/usr/bin/glade-gtk2, should be new AH, apt-get insatll glade installed
Please help me with the help of experts. I have checked a lot on Baidu. no one has solved this problem, and many people have encountered this problem. I kneel down and look forward to it !!!!!
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.