ubuntu 12.04 vim gedit中文亂碼解決 添加中文字元編碼:$sudo vim /var/lib/locales/supported.d/local#添加下面的中文字元集zh_CN.GBK GBKzh_CN.GB2312 GB2312zh_CN.GB18030 GB18030使其生效:$sudo dpkg-reconfigure localesvim:開啟vim的設定檔,位置在/etc/vim/vimrc在其中加入set fileencodings=utf-8,gb2312,gbk,gb18030set termencoding=utf-8set encoding=prc儲存退出source /etc/vim/vimrc此時vim就能正確顯示中文了。--------------------------------------------------------------'gedit: Gedit 3.x 版本設定 (適用於Ubuntu 11.10及以後) gsettings set org.gnome.gedit.preferences.encodings auto-detected "['UTF-8','CURRENT','GB18030','ISO-8859-15','UTF-16']" --------------------------------------------------------------'pdf:$sudo apt-get install xpdf-chinese-simplified xpdf-chinese-traditional #安裝pdf的中文字型$sudo apt-get install poppler-data #安裝解決pdf中文顯示亂碼的軟體$cd /etc/fonts/conf.d $sudo cp 49-sansserif.conf 49-sansserif.conf_backup #先備份下$sudo rm 49-sansserif.conf #刪除在開啟pdf檔案,就能呢個正常顯示中文了