Chinaunix首页 | 论坛 | 博客
  • 博客访问: 1146012
  • 博文数量: 341
  • 博客积分: 12744
  • 博客等级: 上将
  • 技术积分: 4040
  • 用 户 组: 普通用户
  • 注册时间: 2008-05-12 09:34
文章分类
文章存档

2014年(1)

2013年(10)

2012年(17)

2011年(63)

2010年(102)

2009年(107)

2008年(41)

分类: LINUX

2009-02-25 21:44:51

就当是备份了

set autoindent
set shiftwidth=4
set softtabstop=4
set tabstop=4
compiler gcc
set sm
set cin
set fileencodings=utf8
set fileencodings=utf8,gb2312,gbk,big5
filetype plugin on
filetype indent on
set tabstop=4
nmap sd :!sdcv -u 朗道英汉字典5.0 -n =expand("")<CR>
set nocp
set hlsearch
set incsearch
set showcmd
let Tlist_Use_Right_Window=1
let Tlist_Compart_Format=1
let Tlist_File_Fold_Auto_Close=1
"nmap :Explore " 文件列表
"nmap :TlistToggle "函数变量
map :call CompileRunGcc()
func! CompileRunGcc() "编译运行程序
    exec "
wa"
    exec "
!gcc % -o %< -g"
    exec "
! ./%<"
    endfunc
"
nmap :call Search_Word() "打开quickfix
nmap :!ctags -R --c++-kinds=+p --fields=+iaS --extra=+q .
"
nnoremap :Grep "寻找grep
"
inoremap "全能补全
"
nnoremap :A
set updatetime=100
"noremap :call ToggleSketch()
set modifiable
set write
set smartindent
set ambiwidth=double
syntax on
let g:SuperTabRetainCompletionType=2
let g:SuperTabDefaultCompletionType="
<C-P>"
set nocp
autocmd CursorMoved * if pumvisible() == 0|pclose|endif
autocmd InsertLeave * if pumvisible() == 0|pclose|endif
set fo+=mB
set lbr
au BufReadPost * if line("
'\"") > 0|if line("'\"") <= line("$")|exe("norm '\"")|else|exe "norm $"|endif|endif
set nobackup
set noerrorbells
set formatoptions=tcrqn
set foldenable
set foldmethod=manual
nnoremap @=((foldclosed(line('.')) < 0) ? 'zc' :'zo')
set backspace=indent,eol,start
set shortmess=atI
autocmd BufEnter * call DoWordComplete()
let g:WC_min_len=3
let g:WC_accept_key=""
"nmap :Matrix
let g:winManagerWindowLayout="
BufExplorer,FileExplorer|TagList"
let g:winManagerWidth=30
let g:defaultExplorer=0
nmap :WMToggle
nmap :wqa
"
nmap :%s/\s\+$//
nmap :w:bd:bn:q
nmap :w:cp
nmap :w:cn
nmap :wa:make
nmap :wa:TlistUpdate:FirstExplorerWindowb
map :w:FirstExplorerWindow
map :w:BottomExplorerWindow
map :w:bp
map :w:bn
set completeopt=menu

if has("autocmd")
    autocmd FileType xml,html,c,cs,java,perl,shell,bash,cpp,python,vim,php,ruby set number
    autocmd FileType xml,html vmap 'o'>o-->
    autocmd FileType java,c,cpp,cs vmap ''>o*/
    autocmd FileType html,text,php,vim,c,java,xml,bash,shell,perl,python setlocal textwidth=100
    autocmd Filetype html,xml,xsl source $VIMRUNTIME/plugin/closetag.vim
    autocmd BufReadPost *
        \ if line("'\"") > 0 && line("'\"") <= line("$") |
        \ exe "normal g`\"" |
        \ endif
endif "
has("autocmd")

function! SetFileEncodings(encodings)
    let b:myfileencodingsbak=&fileencodings
    let &fileencodings=a:encodings
endfunction
         
function! RestoreFileEncodings()
    let &fileencodings=b:myfileencodingsbak
    unlet b:myfileencodingsbak
endfunction

au BufReadPre *.nfo call SetFileEncodings('cp437')|set ambiwidth=single
au BufReadPost *.nfo call RestoreFileEncodings()

au BufRead,BufNewFile * setfiletype txt

阅读(817) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~