Skip to content
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

"Using Neovim's floating window to break bad habits" #23

Open
statox opened this issue Mar 7, 2021 · 3 comments
Open

"Using Neovim's floating window to break bad habits" #23

statox opened this issue Mar 7, 2021 · 3 comments

Comments

@statox
Copy link
Owner

statox commented Mar 7, 2021

No description provided.

@pyrho
Copy link

pyrho commented Mar 8, 2021

🚀

@bsjaramillo
Copy link

Hi i readed yout post, how can i change the background color or set colorscheme for the window ?

@statox
Copy link
Owner Author

statox commented Jul 16, 2021

@bsjaramillo You can't set a colorscheme for a specific window. What you can do is to play with the highlighting as I showed in the article. You will need to find back this line and change the highlighting group used for Normal:

call nvim_win_set_option(win, 'winhl', 'Normal:ErrorFloat')

For example you could define your own highlighting group and use it like this:

highlight CustomFloatingWindow ctermbg=11 guibg=yellow ctermfg=10 guifg=green
call nvim_win_set_option(win, 'winhl', 'Normal:CustomFloatingWindow')

You get something quite ugly but then you just have to tweak the colors:

image

Some interesting resources:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants