PyGTK, Glade/libglade. What am I doing wrong?
Даниил Рыжков
daniil.re at gmail.com
Sat May 7 00:14:07 EDT 2011
Thanks, Cristian! It works.
> List of Pygtk: http://www.daa.com.au/mailman/listinfo/pygtk
Thanks again. Subscribed :)
2011/5/7 craf <pyclutter at gmail.com>:
> Hi.
>
> Try this:
>
> #!/usr/bin/env python
>
> import gtk.glade
>
> class TestPyGtk:
> """This is an Hello World GTK application"""
>
> def __init__(self):
>
> #Set the Glade file
> self.gladefile = "test.glade"
> self.glade = gtk.glade.XML(self.gladefile)
>
> self.MainWindow = self.glade.get_widget('MainWindow')
> self.MainWindow.show()
> self.MainWindow.connect('destroy', lambda e:gtk.main_quit())
>
>
>
> TestPyGtk()
> gtk.main()
>
> Regards.
>
> Cristian.
>
> List of Pygtk: http://www.daa.com.au/mailman/listinfo/pygtk
--
Best wishes,
Daniil
More information about the Python-list
mailing list