[issue46179] Delete selected item generate "<<TreeviewSelect>>" event or not in different version of tkinter or Python
E. Paine
report at bugs.python.org
Sun Dec 26 11:19:10 EST 2021
E. Paine <xepaine13 at gmail.com> added the comment:
Reproduced on Wish 8.6.9 and 8.6.11 (same behaviour on 8.6.11 as reported on 8.6.12).
I can't comment on why this is happening or which is correct behaviour so I would recommend taking it up with the Tk team https://core.tcl-lang.org/tk/reportlist (tkinter is just a thin wrapper of Tk and doesn't modify the event handling code). If you do take it up with them, here's the minimum equivalent Tcl code:
pack [ttk::treeview .t]
pack [button .b -text delete -command {.t delete 0}]
.t insert {} 0 -id 0 -text 0 -values {V1, V2}
bind .t <<TreeviewSelect>> {puts {select}}
.t selection set 0
----------
nosy: +epaine, serhiy.storchaka
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue46179>
_______________________________________
More information about the Python-bugs-list
mailing list