Red Hat 9, Python and Glade - a mixure not working?

David M. Cook davecook at nowhere.net
Sun Jul 6 14:13:07 EDT 2003


In article <c7427279.0307060306.1345e06 at posting.google.com>, Hans Deragon wrote:


> Thanks for the tips.  But the problem still persist.  Now I run the
> following:

Do you have gnome widgets in your xml file?  You'll need to import gnome.ui
and do a gnome.init().

See the pygtk FAQ:

http://www.async.com.br/faq/pygtk/index.py?req=all

You might also try putting the line

import pygtk; pygtk.require('2.0')

at the top of your file.  Also try running with python -v so you can see
what modules are being loaded.

> So the problem is not my code.  I must assume that the glade module
> for gnome is not adapted for taking in Glade 2 xml?

In fact, libglade2 *only* works with glade 2 files.  glade 1 files have to
be converted first.  

> Different errors, same results.  Nothing works.  However the
> test.glade xml file provided as an example works fine.  I believe that
> there is some widget in my glade2 xml file that is simply not
> supported by python.  I will investigate further the issue later.

I've never encountered this problem with my own glade 2 files.  However, I
don't have a "pristine" RH 9 installation to play with right now.

I suggest taking this problem to the pygtk mailing list.  If it's not
quickly fixable then it needs to be fixed somewhere up the line.

Dave Cook




More information about the Python-list mailing list