2

I've been trying to disable vim from highlighting random words and types for a few hours now. I've noticed vim will highlight specific types when I write python and golang programmes. Even my .vimrc file has random highlighting. I've tried setting set nospell in my .vimrc and have experimented with a number of themes but can't seem to solve this problem, even after researching about it online for a few hours. Here's an example of what I'm talking about: enter image description here Here's my .vimrc file

syntax enable
set number relativenumber
set ts=4
set autoindent
set expandtab
set shiftwidth=4
set showmatch
let python_hightlight_all=1
set nocompatible
filetype off
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()


au BufNewFile,BufRead *.py
    \ set tabstop=4 |
    \ set softtabstop=4 |
    \ set shiftwidth=4 |
    \ set textwidth=79 |
    \ set expandtab |
    \ set autoindent |
    \ set fileformat=unix

set encoding=utf-8

au BufRead *.py set softtabstop=4 shiftwidth=4


set incsearch

Plugin 'VundleVim/Vundle.vim'
Plugin 'itchyny/lightline.vim'
Plugin 'mattn/emmet-vim'
Plugin 'scrooloose/nerdtree'
Plugin 'dracula/vim'
Plugin 'morhetz/gruvbox'
Plugin 'Yggdroot/indentLine'
Plugin 'joshdick/onedark.vim'
Plugin 'vim-scripts/indentpython.vim'
Plugin 'vim-syntastic/syntastic'
Plugin 'nvie/vim-flake8'
Plugin 'airblade/vim-gitgutter'
Plugin 'hashivim/vim-terraform'
Plugin 'Valloric/YouCompleteMe'
Plugin 'fatih/vim-go'
call vundle#end()
color dracula
set laststatus=2
filetype plugin indent on
autocmd StdinReadPre * let s:std_in=1
autocmd VimEnter * if argc() == 0 && !exists("s:std_in") | NERDTree | endif
set cursorline
set nospell
autocmd! FileType python nnoremap <buffer> <F9> :exec '!python' shellescape(@%, 1)<cr>
autocmd FileType go nmap <buffer> <F5>  <Plug>(go-build)
autocmd FileType go nmap <buffer> <F6>  <Plug>(go-run)

1 Answer 1

1

As one of the maintainers of the dracula theme, I believe what you are seeing is dracula’s italics (which fallback to this highlighting in terminals not supporting italics).

As noted in :help dracula, you can turn this off by doing

let g:dracula_italic = 0

before you load dracula.

1
  • Also note that recent versions of dracula need to be loaded in a slightly different way depending on your plugin manager. Check the github out for information.
    – D. Ben Knoble
    Jul 6, 2019 at 16:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.