问题
Once I click into a ttk.Treeview() and select a row, I can click another row but there is no way for me to UNSELECT all the rows, there will always be at least 1 row selected. is there a clever way to allow unselecting the last selected row?
回答1:
Change the name of your var i use treeview=ttk.Treeview() and put in a button [UNSELECT ALL] the following code:
treeview.selection_clear()
来源:https://stackoverflow.com/questions/45376198/how-to-unselect-row-in-a-ttk-treeview-in-tkinter