Gruntfuggly / todo-tree

Use ripgrep to find TODO tags and display the results in a tree view
Other
1.41k stars 135 forks source link

[Bug] Random jump after selecting a list item #663

Open obritany opened 1 year ago

obritany commented 1 year ago

In projects with many TODO/FIXME tags, when you select a tag from the list, the item selector jumps to a random place in the list. This is VERY confusing when you just want to see all the tags in the list in sequence. image For example, I selected the first item and it opened, but after that the selector jumped down two lines and highlighted the third item. Sometimes it jumps a hundred lines...

gondwanasoft commented 1 year ago

I see this behaviour too. I wonder if it's caused by Explorer autoreveal. Or it may be related to [this]([https://github.com/microsoft/vscode/issues/168223](https://github.com/microsoft/vscode/issues/168223)).

gondwanasoft commented 1 year ago

This seems to occur for me only and always when the TODO item is in a non-active editor tab. Clicking an entry in the TODO list ('tags only' view) selects the correct editor tab, but then scrolls the TODO list way down.

gondwanasoft commented 1 year ago

I think it's the trackFile setting that causes this. Before switching editors, trackFile seems to cause the TODO list to select the item at (or near) the cursor position in the editor that's about to be deselected. trackFile should be ignored in this situation.

Turning trackFile off seems to make the issue go away (while, of course, losing that function).