[Pythonmac-SIG] python program in menu bar

Dethe Elza delza at livingcode.org
Thu Sep 27 06:16:47 CEST 2007


Hi Dan,

On 9/26/07, Dan Christensen <jdc at uwo.ca> wrote:
> Can anyone point to a simple example of a python program that runs in
> the menu bar?  I'd like a program that just displays a few characters of
> text in the menu bar, and updates the display once a minute or so.

The first thing to figure out is that Apple calls an app that can live
in the menu bar "NSStatusItem".  Knowing that makes it a LOT easier to
find documentation for writing them.  I highly recommend getting a
copy of AppKiDo to browse the Cocoa docs, if you don't already have
it.

I posted a very simple example of getting an NSStatusItem using PyObjC
on this list awhile back:
http://mail.python.org/pipermail/pythonmac-sig/2005-April/013731.html

Let me know if it helps, or if you need more help getting going.

--Dethe


More information about the Pythonmac-SIG mailing list