customize Tkinter window button~

Howard Lightstone howard at
Thu Dec 4 06:58:13 CET 2003

black <quiteblack at> wrote in
news:mailman.89.1070511965.16879.python-list at 

>  i am with Win2k and had built a window with Tkinter, it has 3 button
>  on its topright corner as common window, but what i want is just one
>  or tow of them. ie, is there any way i can configure the appearance
>  of minimize, maximize and close button ? 

Basically, no.  Those buttons are a function of the Windows standard window 
creation logic.  It is possible to add to or change those buttons (using 
ctypes) - but you are looking at some pretty hairy and poorly documented 
routines (such as the required callbacks for each button).

What you CAN do is use the overrideredirect method to turn off the entire 
top bar and instead put one of your own (Tkinter) buttons there.  Just 
don't forget to handle the (closing, moving the window, etc.,) events for 
the window.

More information about the Python-list mailing list