i have asked how to make a pixmap button before.
i followed the code posted to make my pixmap button.
but strange error occur.
Gtk - critical **: file gtkwidget.c: line 3722
(gtk_widget_get_parent_window): assertion 'widget->parent !=NULL' failed.
here is my code segment:
buttonVBox = GtkHBox()
buttonVBox.set_spacing (100)
Gtestbutton = GtkButton("abc")
Gtestbutton.set_usize(80, 50)
self.Gtestbutton = Gtestbutton
pixfile = pixmap_file('test.png')
pix1 = GnomePixmap (pixfile)
Gtestbutton.realize()
Gtestbutton.remove(Gtestbutton.children()[0])
box = GtkHBox(spacing=5)
box.pack_start(pix1, FALSE, FALSE, 0)
hbox = GtkHBox()
hbox.pack_start(box, TRUE, FALSE, 0)
hbox.show_all()
Gtestbutton.add(hbox)
buttonVBox.pack_start(self.Gtestbutton, TRUE)
what's wrong??
thanks for any help~~~
_______________________________________________
pygtk mailing list [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/