From: Dasn <da...@us...> - 2005-11-18 21:24:21
|
Hi, list! I just found this thread via Web and was sorry for coming back that late. > > > FYI, there"s a known glitch: some files worked by dasn (ie. > > > if_ole.txt, > > > gui_w32.txt, os_msdos.txt, etc.) couldnt be properly viewed under the > > > GBK locale. I dunno how to fix it so far. It might have something > > > to do with the (incorrect/corrupted) utf-8 conversion. > > hmmm. Can you provide a full list of files? What is the symptom? Can > > you read them at all? > > gui_w16.txt, gui_w32.txt, if_ole.txt, intro.txt, map.txt, > os_dos.txt, os_msdos.txt, os_win32.txt, sponsor.txt, > uganda.txt, windows.txt > The encoding problem is interesting: In Win32 enviroment (I do translations under Win2K), if you edit files which come from our repository with gvim DIRECTLY, you'll got all "junky characters". It seems that gvim miss some info to recognize the file encoding, as the 'fileencoding' option is null. The most tricky stuff comes when you edit the files with "notepad.exe", all things look fine in Notepad, then I "save as..." the file in UTF-8 format. Open it again with gvim, now, Vim can recognize the file encoding and auto convert to cp936. The files I had commited were formated like this. According to *help-translated* : [quote] Help files must use latin1 or utf-8 encoding. Vim assumes the encoding is utf-8 when finding non-ASCII characters in the first line. Thus you must translate the header with "For Vim version". [/quote] That means our files are either treated as latin1 encoding or utf-8 encoding when opened as [help] files, so they look fine in the help screen. What if we opened them directly? (I was used to working this way :) So, first I tried adding "enc=utf8" to the modelines of each files I translated, but as lang2 said, that was not recommended and Vim can recognize UTF-8 encoding automatically (I just wondered how? Cause all of our works in UTF-8 encoding look errant to me), then I tried to use notepad as metioned above. I appologize that the files I commited had not been tested on other platforms, and that probably bugs all my friends here. I feel so sorry. Forgive. Recently, I have to use "fileencodings=utf8" in _vimrc to force Vim to treat all kinds of files as UTF-8 encoding. The newly 'cmdline.txt' was generated this way, I wonder whether it'll be okay for other platforms. -Dasn |