Test success, perfect solution.
Just change this file _VIMRC in the Vim folder below.
Come on, tart. It's very powerful!
Set Encoding=utf-8set fileencodings=utf-8,chinese,latin-1if has ("Win32") set Fileencoding=chineseelseset Fileencoding=utf-8endif "fix menu garbled source $VIMRUNTIME/delmenu.vimsource $VIMRUNTIME/menu.vim" fix consle output garbled language Messages Zh_cn.utf-8
Suppose you also adjust the font size and then add the following:
If has ("Win32") set Guifont=courier_new:h15:cansiendif
Let's say you want to set the background color by default:
ColorScheme Slate
This configuration file has been tried by _VIMRC itself.
When you open the file, you go back to your last edit position.
If have ("Autocmd") autocmd bufread *.txt set tw=78 autocmd bufreadpost * \ If line ("' \" ") > 0 && Lin E ("' \" ") <= Line (" $ ") | \ exe "normal g ' \" "| \ endifendif
Suppose you want to set the syntax Gaoliangga this:
ColorScheme Slatesyntax Enable
The above configuration is added in the _VIMRC file in the face of the practice of knowledge ah!
The ultimate solution for vim and Gvim in Chinese garbled in Windows