[pygtk] application custom stock icons not working in ubuntu unity top panel menu

Giuseppe Penone giuspen at gmail.com
Mon Nov 28 07:58:12 WST 2011


Hi,
I recently noticed that in ubuntu unity the top menu of my apps does not
show the (custom) icons I added to the gtk stock, but only the basic stock
icons.
This happens only since the top menu is displayed in the unity top panel
and not in the application window.
In place of the correct icons I see "gtk-missing-image".
On my apps toolbars and other menus those icons are displayed properly, the
problem is only with the top menu.
This happens either with pygtk2 (e.g. http://www.giuspen.com/cherrytree/)
and gobject introspection (e.g.
http://www.giuspen.com/nautilus-pyextensions/).
I use gtk ui manager after integrating the stock icons this way:

factory = gtk.IconFactory()
pixbuf = gtk.gdk.pixbuf_new_from_file(filepath)
iconset = gtk.IconSet(pixbuf)
factory.add(stock_name, iconset)
factory.add_default()

If anybody solved this problem please help.
Cheers,
Giuseppe.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.daa.com.au/pipermail/pygtk/attachments/20111128/fda56cab/attachment.html>


More information about the pygtk mailing list