Re: Tkinter: binding 'enter'/'leave' to canvas items.

Olivier MARCE (alf@lifac6.uucp)
20 Feb 1995 11:17:30 GMT

anthony baxter (anthony.baxter@aaii.oz.au) wrote:

: Has anyone else found that enter/leave bindings dont work with Canvas
: items under Tkinter - for an example, check Demos/tkinter/guido/tst.py -
: the coloured box is supposed to change colour when you enter it, but
: this doesnt work for me, nor do my own applications that attempt to use
: enter/leave work - nothing happens. Binding to, say '<1>' works, but not
: enter or leave. For the moment I'm putting a binding on the canvas for
: 'Motion' and working out where it is myself, but this is gross, and I'd
: like to be able to get rid of it.

You have to modify the bind in 'tag_bind'

It works well.

--

Olivier MARCE Tel : (33) 1 47 40 24 87 LIFAC 24 04 ENS Cachan Fax : (33) 1 47 40 24 64 61 av du Pt WILSON 94235 Cachan Cedex e-mail : O.Marce@lifac.ens-cachan.fr FRANCE (la il faudrait que je rajoute l'URL de ma page, mais d'aucun aurait tendance a croire que je ne fais que ca....)