[pygtk] Controlling application name in window title bar

Edward Stow ed.stow at gmail.com
Tue Mar 4 16:37:42 WST 2008


Hi

I was seeking to control the application name in the window title bar
away from the default applied by gtk - that is the name of the main
module.
Using  something like:

window.set_title("My Applcation")  only results in this name being
appended to the main module filename:

EG  'myapp.py - My Application"   I could rename the module but this
would not suit.

The only way I know is to use the following prior to importing gtk:

import sys
sys.argv[0]= "My Application"

This feels like a hack to me -- but is it the only practical method.

(Using Ubuntu and Nokia Maemo )


-- 

Edward Stow


More information about the pygtk mailing list