The selected row of my ttk treeview shows as a dark blue background with the text white.
If I set the color of the row with a tag, for example:
self.tree.item(item, tags=('oddrow'))
and configure the tag as a color, for example:
self.tree.tag_configure('oddrow', background='lightgrey')
and select the oddrow, the background color does not change (it remains lightgrey) while the text changes from black to white. How can I get the selected row background to be dark blue, whether or not the row is tagged with a color?
Rows not tagged display as black on white, or when selected as white on dark blue.
I tried
ttk.Style().configure('Treeview', selectbackground='blue')
but that didn't do anything.
EDIT: I suppose that when I select an item I could re-tag it as not oddrow, then go back when it's un-selected, but that is rather inelegant.
self.tree.tag_configure('oddrow', background='lightgrey', selectbackground='blue')
? – Steven Rumbalski