TreeControl nodes get underlined and stay that way when hovered over #405
-
I have an app that uses the TreeControl widget to display categorized results of a Pytest run. Whenever a node is hovered over, it gets underlined, but the underline stays even after moving the mouse cursor away from the node. Does anyone know if this is a bug in Textual, or (more likely) an issue with my code? Here's a quick screencast that shows the issue. Screen.Recording.2022-04-19.at.7.51.04.AM.mov |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments 4 replies
-
Not sure if anyone has a clue about this...but it's still an issue for me in 0.1.17. |
Beta Was this translation helpful? Give feedback.
-
OK so I set up a debugger and set some breakpoints, and I can see where the underline is happening now:
OK, great, I understand why the 'leaf' of the tree gets underlined. But shouldn't it de-underline itself when the leaf isn't hovered over anymore? |
Beta Was this translation helpful? Give feedback.
-
The textual/src/textual/widgets/_tree_control.py Lines 273 to 274 in 848bd05 |
Beta Was this translation helpful? Give feedback.
-
If I edit
to
then the underline disappears when the node is not hovered over. I don't know if this is something @willmcgugan would be interested in incorporating into a new version of Textual. I guess in the meantime I'll see if I can ship my package with an altered version of |
Beta Was this translation helpful? Give feedback.
If I edit
_tree_control.py
and I changeto
then the underline disappears when the node is not hovered over.
I don't know if this is something @willmcgugan would be interested in incorporating into a new version of Textual. I guess in the meantime I'll see if I can ship my package with an altered version of
_tree_control.py
.