Todo-tree: Toggle button for showing tags only from open files?

Created on 5 Apr 2019  ·  13Comments  ·  Source: Gruntfuggly/todo-tree

I love having todo-tree.showTagsFromOpenFilesOnly from #31 available to stay focused on big projects but it'd be really nice if there was a UI toggle for it so I could have that on by default but easily see everything without having to change my settings.

fixed

All 13 comments

Would this be easier as a button on the status bar, or a button on the tree view title?

I had been thinking about a button in the row with the collapse & ordering options since I think of it as a filtering operation.

OK - got any ideas for what icon to use? I'm struggling to think of one! 😁

Good question — I wanted to use the filter icon but that's already taken. I'm wondering whether it should just be a toggle between the file-directory and file icons (although I really would like a multi-file icon for that).

How about the file-submodule and the browser icons?

Sure — I think with a tooltip it'll be discoverable enough that people will learn to recognize just about anything.

I've added it to the latest version - you need to set todo-tree.showScanOpenFilesOrWorkspaceButton to enable the button. I've disabled it by default because the button bar is getting a bit crowded - I think I'll add an option to allow more of the buttons to be configurable...

Awesome, thanks!

The only downside I see is that if you click that button when no files are open the entire Todos section of the explorer goes away but it's also not hard to open something and get it back.

You can also use the dedicated tree view from the View->Open View... command.

I could add an option to prevent the tree view from being hidden if it's empty. The nicest thing would be if vscode had an API to allow the view to be expanded/collapsed.

Yeah, I wouldn't worry about it

@Gruntfuggly this reminded me: thanks, this has been working great!

LMK if the disappearing tree ever becomes a problem. :smiley:

Was this page helpful?
0 / 5 - 0 ratings