" Make external commands work through a pipe instead of a pseudo-tty
"set noguipty
" You can also specify a different font, overriding the default font
"if has('gui_gtk2')
" set guifont=Bitstream\ Vera\ Sans\ Mono\ 12
"else
" set guifont=-misc-fixed-medium-r-normal--14-130-75-75-c-70-iso8859-1
"endif
" If you want to run gvim with a dark background, try using a different
" colorscheme or running 'gvim -reverse'.
" ~maverick/VimColorSchemeTest/ has examples and
" downloads for the colorschemes on vim.org
" Source a global configuration file if available
" XXX Deprecated, please move your changes here in /etc/vim/gvimrc
if filereadable("/etc/vim/gvimrc.local")
source /etc/vim/gvimrc.local
endif
set nocp
set nu
" 自动补全命令时候使用菜单式匹配列表
set wildmenu
" 允许退格键删除
set backspace=2
" 启用鼠标
"set mouse=a
" 文件类型
filetype on
filetype plugin on
filetype indent on
" 设置编码自动识别, 中文引号显示
"set fileencodings=utf-8,cp936,big5,euc-jp,euc-kr,latin1,ucs-bom
set fileencodings=utf-8,gbk
set ambiwidth=double
" 移动长行
nnoremap gj
nnoremap gk
" 高亮
syntax on
" 设置高亮搜索
set hlsearch
" 输入字符串就显示匹配点
set incsearch
" 输入的命令显示出来,看的清楚些。
set showcmd
" 打开当前目录文件列表
map :e .
" Taglist
let Tlist_File_Fold_Auto_Close=1
set updatetime=1000
map :Tlist
" 按 F8 智能补全
inoremap
" vim 自动补全 Python 代码
" 来自
autocmd FileType python set complete+=k~/.vim/tools/pydiction
" 自动使用新文件模板
"autocmd BufNewFile *.py 0r ~/.vim/template/simple.py
"Format the statusline
"Nice statusbar
set laststatus=2
set statusline=
set statusline+=%2*%-3.3n%0*\ " buffer number
set statusline+=%f\ " file name
set statusline+=%h%1*%m%r%w%0* " flag
set statusline+=[
if v:version >= 600
set statusline+=%{strlen(&ft)?&ft:'none'}, " filetype
set statusline+=%{&encoding}, " encoding
endif
set statusline+=%{&fileformat}] " file format
if filereadable(expand("$VIM/vimfiles/plugin/vimbuddy.vim"))
set statusline+=\ %{VimBuddy()} " vim buddy
endif
set statusline+=%= " right align
"set statusline+=%2*0x%-8B\ " current char
set statusline+=0x%-8B\ " current char
set statusline+=%-14.(%l,%c%V%)\ %<%P " offset
autocmd FileType python setlocal et sta sw=4 sts=4
filetype plugin indent on
set shiftwidth=4
set cindent
map :!/usr/bin/ctags -R --c++-kinds=+p --fields=+iaS --extra=+q .
if ! has("gui_running")
set t_Co=256
endif
" set background=light gives a different style, feel free to choose between them.
"set background=dark
"colors peaksea
阅读(329) | 评论(0) | 转发(0) |