Vim,为什么我的某些部分被突出显示了?

Vim, why do I have some parts highlighted?

我编辑的时候html,我有像这张图这样的高光

我不想突出显示它。仅供参考,这是我的 .vimrc

set nocompatible               " be iMproved, required

filetype off                   " required
set rtp+=~/.vim/bundle/vundle/ " set the runtime path to include Vundle and initialize
call vundle#rc()
" Bundle 'gmarik/vundle'         " let Vundle manage Vundle, required
Bundle "wookiehangover/jshint.vim" 
Bundle "mru.vim"
Bundle 'godlygeek/tabular'
Bundle 'plasticboy/vim-markdown'
filetype plugin indent on      " required

syntax on                      " Enable syntax highlighting

set wildmenu                   " Better command-line completion
set showcmd                    " Show partial commands in the last line of the screen
set hlsearch

set autoindent
set shiftwidth=2
set softtabstop=2
set expandtab                  " Allow backspacing over autoindent, line breaks and start of insert action

set ignorecase                 " for case insensitive search
set smartcase                  " except when using capital letters

set backup
set backupdir=~/.vim/backup
set directory=~/.vim/tmp

set splitright                " when vertically split, open new window on the right(default, left)
set splitbelow                " when horizontally split, open new window on the bottom(default, top)

" Keyboard Mapping
nnoremap <Leader>b :MRU<CR>  " \b to see the most recent used files
" = to run tidy on html
au FileType html setlocal equalprg=tidy\ -q\ -i\ --show-errors\ 0\ --tab-size\ 4\ --wrap\ 200\ --indent-spaces\ 4

" for markdown plugin
let g:vim_markdown_folding_disabled=1

let g:vim_markdown_no_default_key_mappings=1

编辑----

我喜欢这个 SO 社区。 我关注了所有评论和答案,发现了以下内容;

  1. 已将 <i/> 更改为 <i></i>
  2. syntax off
  3. syntax on

可能是因为 标签...您的语法突出显示可能无法识别您自行关闭它。

否则你可能设置了 'list' 选项(它不在你的 vimrc 中,但插件可能已经添加了它)...如果你的某些代码使用制表符和其他部分空格缩进,那么例如,如果设置了 'list',那么它将仅突出显示选项卡。

尝试:set nolist,看看突出显示的区域是否消失。您可以通过 :retab.

删除杂散的制表符或空格(取决于您的 expandtab 设置)

:set list 的视觉效果取决于您的配色方案和 listchars 的设置。例如,我在家里的 .vimrc 中有 set listchars=tab:▸\ ,eol:¬。有关详细信息,请参阅 :help 'listchars'

如果您希望前导制表符和空格之间仍然有一些视觉上的区别,您可以修改您的配色方案。这有点复杂。来自 Vim 帮助:

The "NonText" highlighting will be used for "eol", "extends" and
"precedes".  "SpecialKey" for "nbsp", "tab" and "trail".

要更改这些语法组的视觉外观,请在 .vimrc 中添加您自己的 :highlight 命令或编辑颜色方案文件。