ConsoleGuiTools
ConsoleGuiTools copied to clipboard
OCGV: Initial focus should be on the results (ListView)
I have rarely had a need to use the filter functionality. Could just be my use-cases.
But I suspect the predominant use of out-gridview and out-consolegridview will be for quick & dirty "show me a smallish list and let me select something", not "show me a giant list and let me filter so I can select something".
Could be wrong.
But if I'm not, I think ListView should be the item that gets focus when ocgv starts. If users want to then filter they can hit shift-tab, shift-tab to go back to it.
Or...
Make Filter an option (-ShowFilter) that is OFF by default.
Disagree strongly about turning Filtering off by default.
My primary use case of Out-GridView is filtering and sorting, then selecting. I often output large results from log files, directories, or data files which often is too much to mess with scrolling in the Console. I run Out-GridView to make sense of it and filter as I go. It is a core experience that I suspect is heavily used.
The default focus on Out-GridView looks to be the grid so setting focus on the ListView would maintain the behavior.
I expect the filter is on by default. This does not force me to use it.
The Out-GridView implementation focuses on the listbox by default, which is one of the reasons I raised this Issue. I think they should behave the same.
Do we have any data on the % of users who use ocgv for filtering vs. just selecting things?
We want to keep filter on because:
- it doesn't take up too much space
- it's useful to be a single click away
The default focus on Out-GridView looks to be the grid so setting focus on the ListView would maintain the behavior.
If this is the case, I'm for making the change to make the list view have focus over the filter.
I was running the old ogv when I noted the focus is on the listbox by default.
In the Powershell/GraphicalTools version that is incorrect; the focus, by default, is not set at all. You have to hit tab to get it to focus on the Quick Search box.
So:
- The original
ogvhad focus on the results by default. - The new
ogvdoesn't set focus at all. ocgvcurrently sets focus on the filter box by default.
If it were up to me I'd go with @TylerLeonhardt's comment above and make the list view have focus over the filter.
I agree the Filter should always be there.
(Tons of other inconsistencies noted between the two, I'll file them separately...)
Fixed in #165