-
-
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
displaying diagnostic count on all open buffers in bufferline and for all buffers with diagnostics in the picker in addition with a red highlight #5536
Conversation
…ostics in buffer picker
As a user, I would prefer the number of diagnostic types, e.g. "2 errors, 5 warnings", rather than "7 diagnostics". Otherwise, the naming is weird, since the diagnostics are not what is counted. What is counted is the number of negative results from all diagnostics that have been run. Side note: This would be suitable to be solved with icons, see #2869 |
That is a fair take. It should be fairly easy to implement. I like the idea of the icons, but in relation to the bufferline, it could get pretty cluttered up there with all the icons and numbers. In that context, I believe that the single number or 9+ would be sufficient. The fact that there is no visible separator that sections off the names of the buffers and anything related to it also doesn't help. Once the design of the bufferline is refined (if that is a discussion), that could be revisited and something similar to But, in the buffer picker, there is sufficient space so it should be fine for the icons and respective numbers to be there without causing clutter. Once the icon support is added, the code implemented in this PR could be modified to use the icons of course. |
I am at a bit of a roadblock with the last task for this PR. I started with directly editing the |
You might want to look at how it's done in #5645 |
The previous commit implements the red highlight for buffers with diagnostics. It is important to note that this does not work well at all with buffers who have long paths. This seems like something that is covered in #2377. In addition, the text approach can be abandoned when icon support is added (#2869) as mentioned a few messages above. |
This PR has been stale for over a year. I also don't think we want to focus on the bufferline too much so I don't see us prioritizing this direction. Thanks for contributing |
Attempts to close #5519
This PR introduces code that displays the diagnostic count for each open buffer in the buffers section in the bufferline. In addition, it also introduces a count for each of the diagnostic severities in the buffer picker for the buffers with diagnostics. Buffers with diagnostics also have a red highlight in the buffer line and buffer picker.
Tasks
Add display for number of diagnostics for each open buffer in the bufferline.
Example Image:
Add display for number of each diagnostic severity for each buffer with diagnostics in the buffer picker.
Example Image:
Add red highlight for buffers with diagnostics in the bufferline.
Example Image:
Add red highlight for each buffer with diagnostics in the buffer picker.
Example Image: