[Tkinter-discuss] Windows beautification

Sorin Schwimmer sxn02 at yahoo.com
Wed Nov 22 20:33:05 CET 2006


Hi All,

1. I'd like to be able to put an icon on the titlebar. I read about using iconwindow together
with a Label, but how? My code:

from Tkinter import *
import Image,ImageTk

root=Tk()
im=ImageTk.PhotoImage(Image.open("mcut16.png")) # a 16x16 image
lb=Label(root,image=im)
root.iconwindow(lb)

yields the following error:

Traceback (most recent call last):
  File "<stdin>", line 1, in ?
  File "/usr/local/lib/python2.4/lib-tk/Tkinter.py", line 1473, in wm_iconwindow
    return self.tk.call('wm', 'iconwindow', self._w, pathName)
_tkinter.TclError: can't use .-1211821748 as icon window: not at top level

How should I do it?

2. I'd like to be able to set the colour of the window decoration. I'd like to distinguish
between similar windows based on their title (and, if possible, border) colour. Can I
accomplish that?

3. Where can I find a detailed documentation about what arguments go in the wm_ family
of  Toplevel methods (meaning, format)?

Thanks,
Sorin




 
____________________________________________________________________________________
Sponsored Link

Online degrees - find the right program to advance your career. 
www.nextag.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/tkinter-discuss/attachments/20061122/80776023/attachment.html 


More information about the Tkinter-discuss mailing list