F
Fulko van Westrenen
Hello,
I use pyGTK in a program with ToggleButton and Pixmap.
The problem I try top solve is changing the pixmap for the
two states of the button. Can it be done? (should be possible),
and someone provide me with working code?
The code I use now is (python-2.2, gtk-1.2):
button = gtk.GtkToggleButton()
button.connect("clicked", do_my_thing)
button.show()
pix,mask = gtk.create_pixmap_from_xpm(window,None,'nice.xpm')
pixmap = gtk.GtkPixmap(pix,mask)
pixmap.show()
button.add(pixmap)
Can someone tell me how to make it work?
Thanks,
Fulko
I use pyGTK in a program with ToggleButton and Pixmap.
The problem I try top solve is changing the pixmap for the
two states of the button. Can it be done? (should be possible),
and someone provide me with working code?
The code I use now is (python-2.2, gtk-1.2):
button = gtk.GtkToggleButton()
button.connect("clicked", do_my_thing)
button.show()
pix,mask = gtk.create_pixmap_from_xpm(window,None,'nice.xpm')
pixmap = gtk.GtkPixmap(pix,mask)
pixmap.show()
button.add(pixmap)
Can someone tell me how to make it work?
Thanks,
Fulko