Loading ...
Sorry, an error occurred while loading the content.
 

Re: Possible bug report.

Expand Messages
  • Bram Moolenaar
    ... The patches solve the problem that we previously put the text as-is on the clipboard. That means no conversion was done and no illegal characters was
    Message 1 of 1 , Mar 20, 2003
      Stanislav Sitar wrote:

      > > > How to reproduce the bug
      > > > 1. get the latest patched Vim from
      > > > http://cream.sourceforge.net/
      > > > 2. install Vim
      > > > 3. start Vim
      > > > 4. press i to start insert mode
      > > > 5. install a new keyboard in windows
      > > > Slovakian, Russian, greek, czech, .......
      > > > 6. switch into that new keyboard using a little blue
      > > > icon in system tray.
      > > > 7. type a few strange looking characters.
      > > > you won't see them properly, because you do not
      > > > have the font set, this shouldn't vorry you
      > > > 8. leave the insert mode <Esc>
      > > > 9. choose Edit -> copy from menu
      > > > 10.Choose Edit -> paste from menu
      > > > 11.The characters you have pasted should be identical
      > > > to those you have just copied. They are not.
      > >
      > > I'm not sure this is the known problem I referred to above. Vim uses
      > > CF_UNICODETEXT itself, thus this should work so long as you have valid
      > > characters in the text. If you have invalid characters (depending on
      > > the value of 'encoding') some information may be lost when converting
      > > to/from Unicode, because we are not supposed to put invalid characters
      > > on the clipboard. E.g., when 'encoding' is "utf-8" the text is
      > > converted to ucs-2 and that can't be done for illegal bytes.
      >
      > All I have done is reinstalling Vim.
      > I have kept my vimfiles directory and my _vimrc file.
      >
      > Now I have uninstaled 'faulty' version and reinstalled
      > 'vanilla plain' vim 6.2 and the problem went away.
      >
      > So it is definitelly related to those patches.

      The patches solve the problem that we previously put the text as-is on
      the clipboard. That means no conversion was done and no illegal
      characters was changed or removed. It also resulted in the wrong text
      to be pasted in other applications (and in a Vim with another 'encoding').
      Now that we do the proper conversions, this will cause illegal
      characters to be changed or dropped.

      The only solution I can think of is to add another type of clipboard
      data, which contains the plain bytes that were copied and the 'encoding'
      used. When pasting, Vim would use this data if 'encoding' matches.
      No conversions would be done on this text.

      --
      hundred-and-one symptoms of being an internet addict:
      137. You decide to stay in college for an additional year or two,
      just so you can have the free Internet access.

      /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
      /// Creator of Vim - Vi IMproved -- http://www.Vim.org \\\
      \\\ Project leader for A-A-P -- http://www.A-A-P.org ///
      \\\ Help AIDS victims, buy at Amazon -- http://ICCF.nl/click1.html ///
    Your message has been successfully submitted and would be delivered to recipients shortly.