gorbit99 / codewindow.nvim

MIT License
431 stars 16 forks source link

Onedark Plugin highlights override Codewindow's #30

Closed Xemptuous closed 1 year ago

Xemptuous commented 1 year ago

I am using navarasu/onedark.vim colorscheme, and with it, I am unable to change CodeWindow's color manually. The highlight group named in onedark/highlights.lua uses FloatBorder to change the borders of the window instead of Codewindow's built-in CodewindowBorder and CodewindowBackground.

Something interesting happens with this plugin though.

When setting the custom highlights:

vim.api.nvim_set_hl(0, 'CodewindowBorder', {fg = '#ffff00'})
vim.api.nvim_set_hl(0, 'CodewindowBackground', {fg = '#ffff00'})

I do not get the expected outcome. Instead, I get some random chunks inside the window being colored (mostly "grey" parts in this example), and the border being unaffected.

For now I am using vim.api.nvim_set_hl(0, 'FloatBorder', {fg = '#4fa6ed'}) (this also works for bg) Highlights Disabled Highlights Enabled FloatBorder used
image image image
gorbit99 commented 1 year ago

Try linking the CodewindowBorder and CodewindowBackground highlight groups to the relevant ones from the highlighting.

I do not get the expected outcome. Instead, I get some random chunks inside the window being colored (mostly "grey" parts in this example), and the border being unaffected.

It's actually probably because "CodewindowBackground" gets used for the dots that do not get any highlight at all. So don't set the foreground to yellow, instead set it to whatever you want those to appear as.

gorbit99 commented 1 year ago

Any change on this?