Python on Windows is complete enough to be a real alternative to Visual Basic. Between wxPython, pyGame, and the win32all extensions you have all the doodads you need to build Windows apps.

Today's exercise was a little program to tell me when my Creative sound driver has been set behind my back to something other than 6.1 surround. It reads a registry key every 15 seconds and updates a system tray icon if things have changed.

Doing it in Python didn't prove too hard. The bloat is bad though; the program is 12 megs in RAM and a 2.5 meg standalone distributable. Still, nicer than trying to remember how to program with Visual Studio.

I found nice sample code for system tray icons: systray_py.txt and Flashing Taskbar Icon. To create a system tray icon for a program:

self.tbicon = wxTaskBarIcon()

If a program ends in .pyw, then pythonw.exe is used to execute the program and a DOS console window doesn't pop up.

icoutils helps build Windows .ico files.

Update: Boa Constructor helps you do visual form design. Thanks, John.

py2exe is good for packaging up programs to redistribute to folks who don't have Python or required site-packages installed.

regmon is useful for figuring out what registry key to watch. Turns out, it's

Creative Tech\Emu10kx\DevCon\

Lots of details.

  2003-08-24 01:46 Z