I want to adapt the default WPF TreeView/TreeViewItem template, so that the entire row can be highlighted, as shown in the image:
However, I've tried several templates from googling, but none of them can really make the effects, some wrong answers were even marked as correct...
There was an answer in codeflow which seems to work, but it add extra C# code, or didn't need extra code but not working perfectly.
I don't want to add extra C# code, but only change the default template. Anyone have any good ideas?
Thanks a lot!
----EDIT----
@Nick, after using your template, it is shown like this,
first, it didn't highlight the "entire" row, by "entire" I mean the widest width of the tree.
second, it highlighted extra areas including the children.