Ⅰ. 插件描述
Highlight lines or patterns of interest in different colorsⅡ. 基本信息
|
Ⅲ. 安装方法
使用Vundle管理器安装
在你的.vimrc下添加:Plugin '/highlight-vim'
… 然后在Vim中运行以下命令:
:source %
:PluginInstall
对于Vundle版本 < 0.10.2,请用上面的Bundle替换Plugin。
使用NeoBundle管理器安装
在你的.vimrc下添加:NeoBundle '/highlight-vim'
… 然后在Vim中运行以下命令:
:source %
:NeoBundleInstall
使用VimPlug管理器安装
在你的.vimrc下添加:Plug '/highlight-vim'
… 然后在Vim中运行以下命令:
:source %
:PlugInstall
使用Pathogen管理器安装
在终端中运行以下命令:cd ~/.vim/bundle
git clone https://github.com/vim-scripts/highlight.vim
Ⅳ. 文档说明
Line mode
<C-h><C-h> Highlight current line
<C-h><C-a> Advance color for next line highlight
<C-h><C-r> Clear last line highlight
Pattern mode
<C-h><C-w> Highlight word under cursor (whole word match)
<C-h><C-l> Highlight all lines having word under cursor (whole word match)
<C-h><C-f> Highlight word under cursor (partial word match)
<C-h><C-k> Highlight all lines having word under cursor (partial word match)
<C-h><C-s> Highlight last search pattern
<C-h><C-j> Highlight all lines having last search pattern
<C-h><C-d> Clear last pattern highlight
<C-h><C-n> Clear all highlights
All above commands work in both normal & insert modes.
<C-h><C-h> also works in visual mode. (Select desired lines & hit <C-h><C-h>)