4

Extending Ingo Karkat's solution to terminal, hi DiffAdd ctermfg=NONE ctermbg=Green hi DiffChange ctermfg=NONE ctermbg=NONE hi DiffDelete ctermfg=LightBlue ctermbg=Red hi DiffText ctermfg=Yellow ctermbg=Red Below are the cterm-colors, if you want to add your preferred color instead of the ones I used. NR-16 ...


4

The AfterColors plug-in (GitHub mirror) provides an after-directory auto-loading mechanism for color schemes. This can however be easily achieved in modern Vim by using the ColorScheme autocommand event (triggered after loading a color scheme and added in v7.0164) and <amatch> (which holds the new color scheme name and was added in v7.4.109). ...


3

There's :h g:indentLine_defaultGroup specially for this case. So it becomes simply let g:indentLine_defaultGroup = 'Comment' In principle, when you need to read in the color from an existing highlight group it's done like that: let color = synIDattr(synIDtrans(hlID('Comment')), 'fg') hlID() returns numerical ID; synIDtrans() follows links if any; ...


3

Highlight in gui or true color terminal with :h termguicolors is not affect by :h cterm, cterm is used for 8, 16, 256 color terminal. This command should change gui LineNr: hi LineNr guifg=#ff0000 guibg=#000000 A quick look at the source, this colorscheme use only 16colors, it doesn't use ansi 16 colors, it works for gui, true color and 256color terminal. ...


3

Try the most recent updated of Goneovim, not the current release 0.4.6. It's not pure vim but a neovim gui, and it does not gain much attention. The indent guides feature of goneovim is native, and works much better than vim/neovim plugins.


3

You need to reorder the commands in your vimrc, to only set the colorscheme after the plug#end() call. call plug#begin('~/.vim/plugged') Plug 'embark-theme/vim', { 'as': 'embark' } call plug#end() colorscheme embark The reason why this is important is that plug#end() is what will modify the 'runtimepath' setting, which is what allows Vim to find plug-in ...


3

It's important that a theme set the g:colors_name variable correctly to match the name of the theme script file, because Vim will use it when it needs to reload the theme (and it does so in a few situations.) I could find at least one cobalt2 theme online that had a commit fixing it from incorrectly setting the variable to cobalt, to setting it correctly as ...


3

You can't change colorscheme for a single window in vim (and probably in neovim too). But if you speak about different colors of regular neovim windows and built-in terminals, you can play around g:terminal_color_0..15. Usually modern colorschemes use them to set terminal colors to match colorscheme, e.g.: let g:terminal_color_0 = '#1c1c1c' let g:...


3

A brief word on how vim-plug works... The main part of a plugin config is a path on GitHub. In your case dracula/vim refers to https://github.com/dracula/vim. What vim-plug needs to do, then, is download/install (using git) the plugin code from that address. But it doesn't happen automatically. It's up to you to run the command :PlugInstall. (And do so each ...


2

Setting 'background' adjusts the default colors for the UI highlight groups (*highlight-groups*), and resets the standard syntax highlight groups (*group-name*) to the default colors for the set background, and thus it must be set before syntax highlighting commands to prevent overriding. If it isn't set explicitly in .vimrc, or in a separate colorscheme ...


2

Final result It should be the same as it's 256color brother (without bold, underline, italic,...) Warning It's not easy, don't do it unless you really want to spend a lot of time in vc(virtual console). Setup terminal Switch to vc, change TERM: TERM=linux-16color Some important desription for linux-16color from ncurse terminfo, pls read it: # 16-color ...


2

Normally Vim colorschemes set a variable g:colors_name nnoremap <expr><silent><leader>C printf(':colorscheme %s<CR>', \ g:colors_name !=# 'OceanicNext' ? 'OceanicNext' : 'Textmate')


2

In modern vim/neovim there is :h g:terminal_ansi_colors (vim) or 16 of g:terminal_color_0 .. g:terminal_color_15 (neovim). If you open gruvbox colorscheme you use, you will find those definitions there (most probably). Basically: your whatever terminal can have palette of base 16 colors defined (there are defaults for each type of terminal, but you can ...


2

In GVim, you can control the 16 ANSI colors used by your terminal with the g:terminal_ansi_colors variable. See :help g:terminal_ansi_colors: In GUI mode or with 'termguicolors', the 16 ANSI colors used by default in new terminal windows may be configured using the variable g:terminal_ansi_colors, which should be a list of 16 color names or ...


2

I use a technique I picked up on reddit from /u/fob3sg: function! ColorCodeBlocks() abort " {{{1 setlocal signcolumn=no sign define codeblock linehl=codeBlockBackground augroup code_block_background autocmd! * <buffer> autocmd InsertLeave <buffer> call s:place_signs() autocmd BufEnter <buffer> call s:place_signs() ...


2

What you're seeing here is vim-markdown's support for highlighting embedded languages in fenced code blocks. In short, vim-markdown will recognize the python in ```python and it will use Python syntax highlighting for that code block. You can find the code that implements that here. It will create a new syntax highlighting group mkdSnippetPYTHON and have ...


2

The highlight of the matching brace is ruled by the MatchParen group. You can customize it with the highlight command. Here's an example: highlight MatchParen guifg=Black guibg=Yellow


2

Using a timer that regularly read the file for what colour mode is in use I solved the question. Here is the script that reads and calls the changes: " Set colour scheme (and more) to light mode function! ColorModeLight() colorscheme onehalflight let g:color_mode_light=1 ... endfunction " Set colour scheme (and more) to dark mode ...


2

So "peachpuff" has just the white background in console. You can patch the source directly, or add this to your vimrc: augroup peachpuff | au! autocmd colorscheme peachpuff hi Normal ctermfg=0 ctermbg=223 augroup end Still not exactly the same as in GUI, but it's much closer now. P.S. Or you can "extend" an existing color scheme ...


2

In the code of peachpuff colorscheme we can find such note: " Note: Only GUI colors differ from default, on terminal it's just `light'.


2

I was able to set these elements to different colors by targeting these two highlight groups: EndOfBuffer NonText So in my case, I added the following to my .vimrc, mirroring the way the colors are established within the distilled colorscheme's files: hi clear EndOfBuffer hi clear NonText hi EndOfBuffer ctermbg=0 ctermfg=8 cterm=NONE guibg=NONE guifg=#...


2

I suspect https://github.com/vim/vim/pull/6970 and related https://github.com/vim/vim/issues/4405 Basically, before the patch it was impossible to put vim into full "default colors mode" as there were no way to do it -- :hi link survived :hi clear. Also cleared highlight groups were impossible to set with :hi def groupname .... I guess that ...


2

This bug was introduced on the Vim runtime update of May 12, 2020, with the update of syntax/sh.vim from version 189 to version 190 from April 14, 2020, which updated the shDoubleQuoted rule to include the part in bold below: syn region shDoubleQuote matchgroup=shQuote start=+"+ matchgroup=shSpecial skip=+\\"+ end=+"+ contained contains=@...


2

The actual code of these two commits can be viewed online here and here. Roughly speaking, Vim now saves value of "def link" in a separate field of the internal "highlight" structure. So upon executing hi clear group(s) are not really cleared, but re-linked to their "def links" (if any). You can do a quick test like this: " ...


2

Yes, it fixes the issue with colorschemes when they were unable to reset all linked highlight groups to their defaults. Now you can change gruvbox and solarized in the same vim session without "leaked" highlights. For the :hi def there was a simple fix -- vim considered a cleared highlight as the one that still had settings applied, thus preventing ...


1

Answer via this Reddit commenter: these floating boxes are controlled by coc itself. In this case the box is called CocHintFloat and can be seen with :hi CocHintFloat. In general :hi Co<tab> shows you all the possible coc highlight groups. To change it, add eg highlight CocHintFloat ctermfg=Red guifg=#ff0000 to your .vimrc. The background colour ...


1

The solution that finally worked for me (suggested in comments) was to add the following to my vimrc file: set termguicolors Apparently Vim was not using the full range of colors available to it.


1

You could use :execute— execute printf('highlight Comment guifg=%s', yellow2)


1

As far as I know the the finest granularity of any color element that can be modified in Vim is the "highlight group" (e.g. :hi Comment guifg=#FFF59D ....). Color "primitives" are dictated by the system. So "blue" means one thing in Windows GUI window and another in an xterm window. While the system defined colors are either non-...


1

This was the color schemes defined in paper color theme. Just pasting this in the vimrc worked! let g:terminal_ansi_colors = [ \'#eeeeee', '#af0000', '#008700', '#5f8700', \'#0087af', '#878787', '#005f87', '#444444', \'#bcbcbc', '#d70000', '#d70087', '#8700af', \'#d75f00', '#d75f00', '#005faf', '#005f87' ]


Only top voted, non community-wiki answers of a minimum length are eligible