nordtheme / nord

An arctic, north-bluish color palette.
https://www.nordtheme.com
MIT License
6.09k stars 170 forks source link

Color for current line and visual blocks missing #207

Closed welblaud closed 1 year ago

welblaud commented 5 years ago

Despite I have set cursoline highlighting up, there is no visible color. The same with visual block selections. The only clue about what is being selected is thanks to vim-indentline chars disappearing. (In gVim it works perfectly.)

At the moment, I have no idea how to run bare-bones Vim with the nord theme without broking my .vim directory.

This is what I get with both nord theme in terminal and in vim (besides the current line highlighting problem, it seems all colors are distorted a bit too): obrazek

arcticicestudio commented 5 years ago

Hi @welblaud, I need some more information regarding your setup (like mentioned in the issue template), otherwise there's no way trying to reproduce the problem:

Also, if you're using the st terminal the problem might be related to nordtheme/vim#166. If so please try to follow the steps that were done in the comments of nordtheme/vim#166 (setting the special variables) to see if this solves the problem.

Benjamin-Lee commented 5 years ago

I am currently facing these issues running iTerm with Fish on MacOS, so it's definitely not an isolated issue.

image
dagolinuxoid commented 4 years ago

Terminal: simple terminal st Theme: patch nordtheme Application: Vim version 8.2.24 Colorscheme: nord OS: ElementaryOS Usually I don't use line highlighting but I tested it via :set cursorline and it works as expected: nord.png PS.

Note that setting the 'cursorline' or 'cursorcolumn' options can cause Vim to respond slowly, especially for large files or files with long lines.

arcticicestudio commented 4 years ago

@dagolinuxoid Thanks for testing and sharing your results, looks like both problems are related to Vim's color space again.

@Benjamin-Lee @welblaud Could you please try to add the following option to your configuration? It looks like Vim uses the 256 color palette instead of the hexadecimal colors defined by Nord.

if (has("termguicolors"))
  set termguicolors
endif
dagolinuxoid commented 4 years ago

BTW unfortunately in some cases in order to enable true color support (make sure your terminal support it), using just set termguicolors isn't enough I managed to make it work by adding these lines into vimrc config file:

" set Vim-specific sequences for RGB colors | enable true colors
let &t_8f = "\<Esc>[38;2;%lu;%lu;%lum"
let &t_8b = "\<Esc>[48;2;%lu;%lu;%lum"
set termguicolors
galah92 commented 4 years ago

I've got the same problem using Windows Terminal. Settingset termguicolors does work and set cursorline now works, but now the integrated terminal in vim (using :term) has the wrong colors. Am I missing something?

MrSicario commented 4 years ago

I'd add the lines to the install guide so people are aware of the issue

BenResTech commented 3 years ago

Confirming that adding the set termguicolors and set cursorline options makes this work for me. This really would be great to add to the installation instructions.

jvoisin commented 2 years ago

It's documented in the readme that only true colours are supported.