VIM配置记录

一步一步按这个文档搭好VIM环境
http://blog.csdn.net/bokee/article/details/6633193

使用过程中一些心得记录下来:

1、Vim是ctrl o(字母)  是用来往回跳。不是什么CTRL + T
2、跳至某个函数则可以通过CTRL 键加MOUSE点击跳进去,也可以通过ctrl +]
3、的确可以做到上文所写的MINIBUF效果,此时切换不同的文件,可以直接用MOUSE双击。
4、这样打造之后,与SOURCE INSIGHT的差距已几乎没有了。
最主要的两个SI功能是:
1、跟进函数 - 与SI一样, 按住CTRL,再用MOUSE单击
2、回跳: ctrl o(字母)  
5、查一个函数被谁引用,就用”ctrl” + “-” + “e” ,

--------我的VIM ------

set tags=tags;/
set nocompatible
set history=400
set autoread
“set mouse=a
syntax enable
“colorscheme elflord
set so=7
set wildmenu
set ruler
set cmdheight=2
set nu
set backspace=eol,start,indent
set whichwrap+=<,>,h,l
set showmatch
set mat=2
set hlsearch
set is

set nofen
set fdl=0

set expandtab
set shiftwidth=2
set ambiwidth=double
set smarttab
set ts=4
set lbr
set tw=500
set selection=inclusive

set ai
set sw=4
set si
set cindent “usage: select codes, press ‘=’ key, the codes will autoindenting
set wrap

if has(“multi_byte”)
if getfsize(expand(“%”)) > 0
set fileencodings=ucs-bom,utf-8,cp936,big5,euc-jp,euc-kr,latin1
else
set fileencodings=cp936,big5,euc-jp,euc-kr,latin1
endif

if v:lang =~ “^zh_CN”
set encoding=cp936
set termencoding=cp936
set fileencoding=cp936
endif

if v:lang =~ “utf8 "||v:lang= "UTF8
set encoding=utf-8
set termencoding=utf-8
set fileencoding=utf-8
endif
else
echoerr “Sorry, this version of (g)vim was not compiled with multi_byte”
endif

if &diff
let Tlist_Auto_Open=0 “don’t auto pen when compare two files
else
let Tlist_Auto_Open=1 “auto pen Tlist when open a file
endif

nmap s :cs find s =expand(“”)
nmap g :cs find g =expand(“”)
nmap c :cs find c =expand(“”)
nmap t :cs find t =expand(“”)
nmap e :cs find e =expand(“”)
nmap f :cs find f =expand(“”)
nmap i :cs find i ^=expand(“”)$
nmap d :cs find d =expand(“”)
set cscopequickfix=s-,c-,d-,i-,t-,e-,g-
nmap :cnext
nmap :cprev

map :!ctags -R –c++-kinds=+p –fields=+iaS –extra=+q .

set nocp
filetype plugin on

set mouse=a ” Enable mouse usage (all modes) “使用鼠标

“使用SUPERTAB
let g:SuperTabDefaultCompletionType=”context”
” SuperTab使用很简单,只要在输入变量名或路径名等符号中途按Tab键,就能得到以前输入过的符号列表,并通过Tab键循环选择

“wnmanager
let g:miniBufExplMapWindowNavVim = 1
let g:miniBufExplMapWindowNavArrows = 1
let g:miniBufExplMapCTabSwitchBufs = 1
let g:miniBufExplModSelTarget = 1
let g:miniBufExplMoreThanOne=0

colo evening

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值