Community technical support mailing list was retired 2010 and replaced with a professional technical support team. For assistance please contact: Pre-sales Technical support via email to sales@march-hare.com.
Tony Hoyle wrote: > Wu Yongwei wrote: > >> 1) Using a non-default code page (like CP437) is allowed and normal >> under Windows, esp. considering that Windows will force the code page >> to 437 if a DOS application (like edit, arj, f-prot, etc.) is invoked. >> Some applications, like hiew, works well only under CP437. > > As far as applications are concerned Windows has only two codepages - > the current ANSI codepage, and Unicode (there is the OEM codepage but > that's just a DOS compatibility hack as far as I can see). cvsnt is > increasingly Unicode/Utf8 internally but to work from the command line > it needs to know and work with the ANSI codepage. No, console applications can do more than that. On my Windows box, I can use code pages 437 (OEM English), 1252 (Windows Latin1), 932 (Japanese), 936 (Simplified Chinese), 950 (Traditional Chinese), etc. in different command prompt boxes simultaneously. When I type commands like `dir' at the command prompt, messages will be in Simplified Chinese if the current code page is 936, and will be in English if the current code page is 437 or 1252. That's why I believe the `A' APIs are not fit for a console application. (More surprising things follow.) > DOS applications are irrelevant in this contect - cvsnt is not a DOS > application. The sole reason to mention DOS applications is that they can make a code page switch, and make error messages after that unreadable. >> 2) All messages in CVSNT is in English. Why should the error messages be > > That's a temporary situation.. full localisation is in the future (not > that far off either). The old CVS couldn't do it because it understood > nothing but US-ASCII anyway.. the days are long gone that an > application can be that simplistic about language. That is good. I hope it will be aware of the current code page and do something appropriate, or respect some settings like either the Unixy environment variable LANG (like Vim), or some configuration file; but it should not call an `A' API that does not know anything about consoles (and locales: see below). >> an exception? I was really expecting all English messages. I cannot >> find a workaround to make it English. > > Switch your windows to english language, and it'll generate all its > messages in english. I suspect Control > Panel->Languages->Advanced->Language for non-Unicode Programs would do it. > > There's no particular reason to favour english over any other language > cvsnt actually has a disproportionate number of japanese and german > users - there's more of an argument for all the messages to be in german > than english... I know this (and do this often), but in GUI application I often need Chinese, and rebooting is slow.... AND THE SURPRISING FACT IS (I tested it): The error message of CVSNT is unreadable (question marks indeed) when I switch the system locale to English! The error messages seem hard-coded in the system DLL. >> 4) Fixing other applications is more difficult than changing CVSNT in >> this case, and there might be too many applications to `fix'. For one >> thing, I even do not know how to detect the `ANSI' code page in Vim >> scripting (there are more things to do than that if I want to make the >> Chinese message correct in a UTF8-encoding Vim with a CVS integration >> script). > > It shouldn't need to. > > A correctly functioning Windows application, when calling another > Windows Application, should assume that all its output is in the current > ANSI codepage, and transcode it to whatever it needs internally if it's > using something else. If Vim is not doing this then file a bug with > them. It's not something that cvsnt can fix. It is not that simple. Vim redirects the result of a command to a file, and read that file later. I believe this can also be solved if I hack enough. However, I feel that changing CVSNT might be a better idea (it seems you did not agree :-), and I am still trying to persuade you). > Anyway *what* error messages? It's pretty rare to see network error > messages on a functioning system.. you see them during setup of course > but once it's working it's fine. Not very often, but our company network can sometimes go insane. I thought I can encounter something like `Network unreachable' or `Connection timed out'. Sometimes I need to do something to go on. > Tony Best regards, Yongwei