-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Symbol picker should open immediately, without waiting for contents to load #8622
Comments
I like this idea and I think the change would be quite small to change the behavior this way: streaming results into the picker is very easy thanks to nucleo (#7814). There's a general problem with the picker though that it doesn't have a way to show the progress of whatever task is adding items to the picker. So if we make a change to stream in the symbols when we get the RPC response from the language server, we would open the picker and see nothing and then symbols would suddenly appear (or not, if there are no symbols in the file). The problem is there for other picker use-cases as well like dynamic global search (#196) - the picker should have a way to indicate that it has finished searching for the pattern. I talked to @pascalkuthe about this and he has a clever idea for a change in nucleo that would allow you to cheaply detect when the task that streams in items is done. nucleo Injectors are ref counted so when we see the number of references drop to zero we know we're no longer streaming in new items. We're not sure how the picker should show that it is running/working though. The braille spinner we use for LSP progress is a little complicated rendering-wise and visually distracting so it'd be nice to find something more subtle. |
That's the indicator that nucleo is working on filtering the available items. For a simple progress indicator, we could repurpose that element to say "running" when the items are being streamed in and "filtering" when nucleo is working |
It shows that even if I don't type in any filter though, and it disappears as soon as all items are loaded 🤔 The running/filtering messages sound good to me personally! |
Say I open helix for a particular file and immediately press space+s to open the symbol picker and start typing my search term. What happens today is that the symbol picker takes time to open probably because the LSP is still starting up. The keys I typed for the search query end up being interpreted as keystrokes for the editor.
The picker should open immediately, my keys should go into the picker's filter, and the contents of the picker can load slowly if the LSP is slow or whatever. AFAIU, async buffering into the picker is already supported.
The text was updated successfully, but these errors were encountered: