However, I'm not getting anywhere in actually making it work. Here's my best guess (in Python): Code: PixBuf = gtk.gdk.pixbuf_new_from_file("image.png") Image = gtk.image_new_from_pixbuf(PixBuf) Button = gtk.Button() Button.set_image(Image) MapMask = PixBuf.render_pixmap_and_mask() Mask = MapMask[1] self.add(Button) Button.shape_combine_mask(Mask, 0, 0) Button.show() self.show() This gets me a button with the correct image, but no masking. Can anybody spot what I'm doing wrong?
PixBuf = gtk.gdk.pixbuf_new_from_file("image.png") Image = gtk.image_new_from_pixbuf(PixBuf) Button = gtk.Button() Button.set_image(Image) MapMask = PixBuf.render_pixmap_and_mask() Mask = MapMask[1] self.add(Button) Button.shape_combine_mask(Mask, 0, 0) Button.show() self.show()