{"id":50,"date":"2010-12-26T15:42:48","date_gmt":"2010-12-26T07:42:48","guid":{"rendered":"http:\/\/www.magki.com\/blog\/?p=50"},"modified":"2010-12-26T16:01:33","modified_gmt":"2010-12-26T08:01:33","slug":"fix-gvim-for-chinese-utf8-support-in-windows","status":"publish","type":"post","link":"http:\/\/www.ijony.com\/blog\/2010\/12\/fix-gvim-for-chinese-utf8-support-in-windows.html","title":{"rendered":"windows \u4e0b gVim \u7684\u4e2d\u6587utf8\u652f\u6301"},"content":{"rendered":"<p>\u505a\u5f00\u53d1\u517b\u6210\u7684\u4e60\u60ef\uff0c\u7f16\u7801\u4e00\u8d2f\u7528 utf8 \u683c\u5f0f\u3002\u4ee5\u524d\u4e00\u76f4\u6ca1\u4e8b\uff0c\u6700\u8fd1\u5728 windows \u4e0b\u88c5\u4e86 gVim \u51c6\u5907\u597d\u597d\u7ec3\u7ec3\u5feb\u6377\u952e\u53d1\u73b0 gVim \u6253\u5f00 UTF8 \u7f16\u7801\u7684\u6587\u4ef6\u4e2d\u6587\u90fd\u662f\u4e71\u7801\u3002\u7f51\u4e0a\u641c\u4e86\u4e00\u4e0b\u4fee\u6539\u4e86 vim \u7684\u914d\u7f6e\u6587\u4ef6 _vimrc \u89e3\u51b3\u4e86\u8fd9\u4e2a\u5c0f\u95ee\u9898\uff0c\u628a\u4e0b\u9762\u8fd9\u6bb5\u914d\u7f6e\u4ee3\u7801\u63d2\u5165\u5230 _vimrc \u6700\u524d\u7aef\u5c31\u53ef\u4ee5\u4e86\u3002<\/p>\n<p>if has(&#8220;gui_running&#8221;)<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;set encoding=utf-8<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;set fileencodings=utf-8,chinese,latin-1<\/p>\n<p>&nbsp;&nbsp;&nbsp;&nbsp;if has(&#8220;win32&#8221;)<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;set fileencoding=chinese<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;else<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;set fileencoding=utf-8<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;endif<\/p>\n<p>&nbsp;&nbsp;&nbsp;&nbsp;let &#038;termencoding=&#038;encoding<\/p>\n<p>&nbsp;&nbsp;&nbsp;&nbsp;source $VIMRUNTIME\/delmenu.vim<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;source $VIMRUNTIME\/menu.vim<\/p>\n<p>&nbsp;&nbsp;&nbsp;&nbsp;language messages zh_CN.utf-8<br \/>\nendif<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u505a\u5f00\u53d1\u517b\u6210\u7684\u4e60\u60ef\uff0c\u7f16\u7801\u4e00\u8d2f\u7528 utf8 \u683c\u5f0f\u3002\u4ee5\u524d\u4e00\u76f4\u6ca1\u4e8b\uff0c\u6700\u8fd1\u5728 windows \u4e0b\u88c5\u4e86 gVim \u51c6\u5907\u597d\u597d [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[4],"tags":[],"_links":{"self":[{"href":"http:\/\/www.ijony.com\/blog\/wp-json\/wp\/v2\/posts\/50"}],"collection":[{"href":"http:\/\/www.ijony.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.ijony.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.ijony.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.ijony.com\/blog\/wp-json\/wp\/v2\/comments?post=50"}],"version-history":[{"count":0,"href":"http:\/\/www.ijony.com\/blog\/wp-json\/wp\/v2\/posts\/50\/revisions"}],"wp:attachment":[{"href":"http:\/\/www.ijony.com\/blog\/wp-json\/wp\/v2\/media?parent=50"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.ijony.com\/blog\/wp-json\/wp\/v2\/categories?post=50"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.ijony.com\/blog\/wp-json\/wp\/v2\/tags?post=50"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}