Tkinter: tkButtonDown, tkButtonEnter, tkButtonInvoke, tkButtonLeave, tkButtonUp

akineko akineko at
Tue Sep 2 04:01:17 CEST 2008

On Sep 1, 6:34 pm, "Guilherme Polo" <ggp... at> wrote:
> This is an illusion you have, calling those methods are not the way
> for explicitly controlling button's behavior, not more than generating
> proper events. The explicit way is to not use a button, instead
> (ab)use Canvas.

Some of my custom widgets used Canvas.
When I designed the "sticky" button widget, I briefly considered use
of Canvas but I rejected because the one I wanted is nothing but
Button (except "sticky" behaviour).
I understand that use of Canvas provides greater flexibility but I
felt it was over-kill.
Your insights are very helpful for me and other people when designing
a custom widget.


More information about the Python-list mailing list