Código:
#!/usr/bin/env python import pygtk pygtk.require('2.0') import gtk from gtk import glade glade.XML('hola.glade') gtk.main()
Cita:
fichero hola.glade:(otro.py:18382): libglade-WARNING **: Expected <glade-interface>. Got <interface>.
(otro.py:18382): libglade-WARNING **: did not finish in PARSER_FINISH state
Traceback (most recent call last):
File "otro.py", line 6, in <module>
glade.XML('hola.xml')
RuntimeError: could not create GladeXML object
(otro.py:18382): libglade-WARNING **: did not finish in PARSER_FINISH state
Traceback (most recent call last):
File "otro.py", line 6, in <module>
glade.XML('hola.xml')
RuntimeError: could not create GladeXML object
Código:
He buscado de que es el error pero no encuentro nada <?xml version="1.0"?> <interface> <requires lib="gtk+" version="2.16"/> <!-- interface-naming-policy project-wide --> <object class="GtkWindow" id="window1"> <property name="visible">True</property> <property name="window_position">center</property> <property name="default_width">440</property> <property name="default_height">250</property> <child> <object class="GtkLabel" id="label1"> <property name="visible">True</property> <property name="label" translatable="yes">Hello world</property> </object> </child> </object> </interface>