2008-08-09

vimrc - VIM 的設定檔

vim 是什麼? Linux 下的老牌文字編輯器,詳細說明請看Wikipedia-vim

/etc/vim/vimrc 中的常用設定

set nu "顯示行號
set tabstop=4 "Tab 的空白數
set hls "加亮搜尋到的關鍵字
set cursorline "標註顏色至游標整行
syntax on "開啟語法加亮


" 選擇語法加亮的配色,配色檔目錄(/usr/share/vim/vim72/colors)
"colorscheme blue
"colorscheme darkblue
colorscheme default
"colorscheme delek
"colorscheme desert
"colorscheme elflord
"colorscheme evening
"colorscheme koehler
"colorscheme morning
"colorscheme murphy
"colorscheme pablo
"colorscheme peachpuff
"colorscheme ron
"colorscheme shine
"colorscheme slate
"colorscheme torte
"colorscheme zellner



" gVim UTF-8 支援設定
set fileencodings=utf-8,big5,euc-jp,gbk,euc-kr,utf-bom,iso8859-1
"set encoding=utf8 "不設定 menu bar 就不會變亂碼.
set tenc=utf8


if has("gui_running")
set termencoding=utf-8
else
set termencoding=big5
endif


參考來源:
gvim編UTF-8的文件

0 回應: