syntax_tree_view: Fix highlights persisting after view was closed (#47638)

Also ensured that we clear only the highlights of the current view
(which probably would have been the the case almost always anyway).

Release Notes:

- Fixed a small issue where highlights of the syntax tree view would
persist after the view was closed.
3b5443ba96Finn Evers committed on 1/26/2026, 11:07:01 AM· committed by GitHubparenta1df9ba
4 files changedLine totals unavailable