use_winbar broken after default is set to false
mehalter opened this issue · 10 comments
Hey, just a heads up that I'm pretty sure the use_winbar
feature was broken when you made the default false
. When you do the table merge, if you merge a table with use_winbar = nil
that is treated as the value not being set and will not change the default false
to nil
. As it is now, it is impossible to set use_winbar
to nil
I think it does make sense to have the nil
setting as the default since it is smart in deciding when to use winbar
. For most people who have cmdheight=0
they might not want their statusline to start shifting up and down as this can make the UX feel a little weird. I think it's a good idea to have the smart option as the default as it will fit what most people want.
Also fixes the problem I described above where there's no way to tell if a user is trying to set a key to nil
since all keys that don't exist in a table are nil
. Ex. config.some_non_existent_key
will equal nil
@mehalter Well, I guess we can change the value to anything other than a boolean then? We can set it to an empty string so it will use the winbar?
Yeah you could make it a string "always", "never", "smart" would be logical options
Yep let's go with that
Awesome, sounds perfect. Thanks for your help getting this feature added in! AstroNvim thanks you 🥳
Let me test it. Looking at the commit the only change that needs to happen is in the config we should do use_winbar = "never"
rather than true
and then we need to update the README. That shouldn't affect the functionality, but it will make things more clear. Let me test it out to see if it works though!
Just tested it fully and it works great! Only thing left is to fix the default config value and update the README :)
Ah, I just saw that you did that. Perfect! I think it looks great! I'll go ahead and close this. Looking forward to the new release!
Just saw you tagged the release. For reals, thank you so so so much! Keep up the great work!