vim-devicons icon indicating copy to clipboard operation
vim-devicons copied to clipboard

NERDTree icons all pink OR with square brackets if I change color.

Open ubaldot opened this issue 3 years ago • 1 comments

Required Info

NERDTree icons are all pink OR with square brackets if I change color.

According to the documentation, I have added the following lines to my .vimrc


function! NERDTreeHighlightFile(extension, fg, bg, guifg, guibg)
exec 'autocmd FileType nerdtree highlight ' . a:extension .' ctermbg='. a:bg .' ctermfg='. a:fg .' guibg='. a:guibg .' guifg='. a:guifg
exec 'autocmd FileType nerdtree syn match ' . a:extension .' #^\s\+.*'. a:extension .'$#'
endfunction

au VimEnter * call NERDTreeHighlightFile('jade', 'green', 'none', 'green', '#151515')
au VimEnter * call NERDTreeHighlightFile('ini', 'yellow', 'none', 'yellow', '#151515')
au VimEnter * call NERDTreeHighlightFile('py', 'yellow', 'none', 'yellow', '#151515')
au VimEnter * call NERDTreeHighlightFile('md', 'blue', 'none', '#3366FF', '#151515') 
au VimEnter * call NERDTreeHighlightFile('yml', 'yellow', 'none', 'yellow', '#151515') 
au VimEnter * call NERDTreeHighlightFile('config', 'yellow', 'none', 'yellow', '#151515') 
au VimEnter * call NERDTreeHighlightFile('conf', 'yellow', 'none', 'yellow', '#151515') 
au VimEnter * call NERDTreeHighlightFile('json', 'yellow', 'none', 'yellow', '#151515') 
... 

but I got the square brackets in the file types for which I have changed color (see screenshot below).

As per documentation, :echo g:webdevicons_conceal_nerdtree_brackets returns 1.

  • [x] I have searched the issues for my issue and found nothing related and/or helpful
  • [x] I have read or at least glanced at the FAQ
  • [x] I have read or at least glanced at the Wiki
  • [x] VimDevIcons is the last loaded vim plugin?
  • [x] What 9.0 of vim are you using?
  • [x] What FiraCode are you using?
  • [x] GUI vim?
  • [x] Windows 10

Optional Info

  • [x]

image

ubaldot avatar Oct 06 '22 14:10 ubaldot

I'm having this problem as well. Whenever I re-source $MYVIMRC — which has a colorscheme line in it — even though the color stays the same, the icons render with square brackets around them.

igbanam avatar Apr 01 '24 10:04 igbanam