-
Notifications
You must be signed in to change notification settings - Fork 186
fix(statusline): set hl_group for statusline separators #616
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
base: main
Are you sure you want to change the base?
Conversation
f38e019
to
5ede517
Compare
5ede517
to
5dd5c9f
Compare
This PR is stale because it has been open 30 days with no activity. |
5dd5c9f
to
c07851e
Compare
Any comments on this? Been using it locally without issue for a month+. |
nvim-lualine/lualine.nvim#1368 was merged, so this is the only piece missing to address the miscolored statusline gaps. Anything you'd like me to do to make this mergeable? |
This PR is stale because it has been open 30 days with no activity. |
Ready for comments whenever you are :) |
This PR is stale because it has been open 30 days with no activity. |
keeping this alive |
Description
Currently, statusline segments have custom highlight groups, but the separators between the segments don't get any highlight group applied, resulting gaps/discontinuities in the statusline background with most colorschemes. This PR applies the highlight group provided to
trouble.statusline
, if any, to the separators as well as to any segments that don't supply their own highlight group.The fix involves a slight refactor of the
fix_statusline
functionality such that segment hl backgrounds are substituted in advance rather than via post hoc search and replace.I also added a clause to filter out empty segments which would otherwise result in extraneous separators, usually appended to the end of the statusline string. Let me know if these empty segments/extra separators were intentional and I'll revert that change.
Related Issue(s)
The author closed the issue when a workaround was posted, but I figured it would be worthwhile to fix this properly in the plugin.
Screenshots
Before: Note the gap between

open
andview:wait
as well as the double gap afterview:wait
After: The single remaining gap after

view:wait
is due to a bug in lualine.nvim; I'm submitting a PR there tooEDIT: With nvim-lualine/lualine.nvim#1368: No gaps!
