Hi, I recently noticed that in ubuntu unity the application indicator (which replaces the system tray) does not show the custom icons I added to the gtk stock, but only the basic stock icons. In place of the correct icons I see "gtk-missing-image". On my apps toolbars and menus those icons are displayed properly, the problem is only with the top application indicator. 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() ################################### then the appindicator code: ############################## ..... try: import appindicator HAS_APPINDICATOR = True except: HAS_APPINDICATOR = False .... if HAS_APPINDICATOR: self.ind = appindicator.Indicator("x-tile", "indicator-messages", appindicator.CATEGORY_APPLICATION_STATUS) self.ind.set_status(appindicator.STATUS_ACTIVE) self.ind.set_attention_icon("indicator-messages-new") self.ind.set_icon("x-tile") self.ind.set_menu(self.ui.get_widget("/SysTrayMenu")) else: self.status_icon = gtk.StatusIcon() self.status_icon.set_from_stock("Tile Quad") self.status_icon.connect('button-press-event', self.on_mouse_button_clicked_systray) self.status_icon.set_tooltip(_("Tile the Windows Upon your X Desktop")) ############################### for full code: hg clone https://giuspen-x-tile.googlecode.com/hg/ hg_x-tile cd hg_x-tile hg up x-tile2 The icons are visible when using system tray, not with application indicator If anybody solved this problem please help. Cheers, Giuseppe.
_______________________________________________ pygtk mailing list pygtk@daa.com.au http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://faq.pygtk.org/