On Thu, Apr 23, 2009 at 4:41 AM, Dennis Benzinger
<[email protected]> wrote:
...
> What does :set enc? return? If enc is not set to a Unicode encoding I
> think Vim won't be able to represent every Unicode character in memory.
> Therefore you'll get a conversion error when Vim tries to convert your
> file from UTF-16LE to its internal encoding.

When I modified some of my Vim settings following this guide:
http://vim.wikia.com/wiki/Working_with_Unicode

Before opening the file, everything worked.
So now I will go back and make 1 change at a time and see if I can
still open the file.


The Vim tip is good, but it doesn't really spell things out for this
type of person:
1.  Works in latin1 (English) all day
2.  Only occassionally opens up a unicode file

I am worried that adding this to my vimrc:

if has("multi_byte")
  if &termencoding == ""
    let &termencoding = &encoding
  endif
  set encoding=utf-8
  setglobal fileencoding=utf-8 bomb
  set fileencodings=ucs-bom,utf-8,latin1
endif

Will affect all the new files I create and end up turning them into
unicode files rather than my regular latin1 files.

The only changes I want to make is to allow me to open unicode files
if the file is already in unicode and leave everything else as I have
it today (with default values on an English XP machine).

Thanks for the response.
Dave

--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

Reply via email to