PyGTK tray menu has annoying scroll arrows

Reply

Join Date: Dec 2008
Posts: 1
Reputation: ewall is an unknown quantity at this point 
Solved Threads: 0
ewall ewall is offline Offline
Newbie Poster

PyGTK tray menu has annoying scroll arrows

 
0
  #1
Dec 5th, 2008
I've been working on a simple little PyGTK app that shows an icon in the system tray. When you right-click, the pop-up menu appears as expected. However, first the menu appears with just some up and down scroll arrows, and I have to scroll down before it fills in and shows the 3 items, and then the scroll arrows disappear.

I've searched everywhere (GTK+ API, etc.) and can't seem to find a way to disable those scroll arrows, which are clearly not needed. The relevant code snippet is below...

  1. def _createMenu(self):
  2. """
  3. Creates the pop-up menu for the icon.
  4. """
  5. self.menu = gtk.Menu()
  6. quit = gtk.ImageMenuItem(gtk.STOCK_QUIT)
  7. quit.connect("activate", self.destroy)
  8. about = gtk.ImageMenuItem(gtk.STOCK_ABOUT)
  9. about.connect("activate", self.ShowAbout)
  10. configure = gtk.ImageMenuItem(gtk.STOCK_PROPERTIES)
  11. configure.connect("activate", self._edit_config)
  12.  
  13. self.menu.add(about)
  14. self.menu.add(configure)
  15. self.menu.add(quit)
  16.  
  17. self.menu.show_all()
  18.  
  19. def _showMenu(self, status_icon, button, activate_time):
  20. self.menu.popup(None, None, gtk.status_icon_position_menu, button, activate_time, status_icon)

Further info: I'm using Python 2.52 with GTK+ 2.12.9r2 on Windoze, if that makes any difference.

TIA-- ~ewall
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Other Threads in the Python Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC