On 10/09/08 04:15, John Beckett wrote: > Vadim Zeitlin wrote: >> So, for example, opening a file "Аня.vcf" opens the file >> "???.vcf" on my English Windows system. > > Tony's advice about encoding might fix the situation. I have the following in > my > vimrc: > > set encoding=utf-8 > > and can open a file with the name you mentioned on Windows. The font I'm using > displays squares for the file name characters, but the window title is > correct. > > John
Beware that if your keyboard includes some characters which aren't strict 7-bit US-ASCII, the above ":set" line (used alone) will probably make them unusable, especially in Console Vim but also in some GUI versions (including, I think, Windows), unless you take special care of those characters. This is what I use: if has('multi_byte') " multibyte features compiled-in if &encoding !~? '^u' " the OS locale is not Unicode if &termencoding == '' " empty means 'use &enc' let &termencoding = &encoding " avoid clobbering keyboard codes endif set encoding=utf-8 " we can do it, now that the kb is taken care of endif set fileencodings=ucs-bom,utf-8,latin1 " heuristics for existing files setglobal bomb fileencoding=latin1 " defaults for new files " 'bomb' doesn't apply to latin1 " it applies when 'fenc' is manually set to Unicode endif The ":setglobal" line is optional, it is a question of personal preference. In the 'fileencodings' (plural) setting, ucs-bom should be first, and an 8-bit value should be last (because anything after the first 8-bit value is never used). Best regards, Tony. -- Pure drivel tends to drive ordinary drivel off the TV screen. --~--~---------~--~----~------------~-------~--~----~ You received this message from the "vim_dev" maillist. For more information, visit http://www.vim.org/maillist.php -~----------~----~----~----~------~----~------~--~---