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

RE: Win32 clipboard and pasting unicode from other apps

Expand Messages
  • Maiorana, Jason
    ... from ... GAK, that patch is for GTK gvim and console vim s connection to the X server. I dont know the first bit about gvim on windows. (Does the Win32
    Message 1 of 32 , Nov 14, 2002
    • 0 Attachment
      > I think I know why gvim on Win32 breaks unicode cut/copy and pasting
      from
      > other apps, but I don't know enough (yet) about the vim internals and
      > especially multibyte to fix it.
      >There are a few patches that have been made, but not included yet. If
      >I'm not mistaken then this one is the most recent:
      > http://members.telocity.com/~seer26/UTF8_STRING.patch


      GAK, that patch is for GTK gvim and console vim's connection to
      the X server. I dont know the first bit about gvim on windows.
      (Does the Win32 version use GTK?)

      The patch basically turns on support for the X clipboard format
      know as "UTF8_STRING", which is used by gtk2, mozilla, etc, pretty
      much any recent app uses it instead of "COMPOUND_TEXT". (Also
      in my apps I dont bother to support anything but UTF8_STRING,
      so it help me personally too.)

      On my system "COMPOUND_TEXT" doesnt work because i muck around with
      my locales etc too much, so in order for me to copy/paste multilanguage
      stuff I needed "UTF8_STRING" pretty badly. PS, ive been using the patch
      with vim/gvim for several months now, with no problems.

      So i think my patch is a bit X-windows oriented.
      As for ms-windows, doesnt that use some sort of UTF-16 encoding
      everywhere?
      I dont have any way to write windows code, so I cant help you with
      that...
    • Bram Moolenaar
      ... That has a catch 42 problem: I would like to test the whole thing before sending the patch into the world. ... I didn t change the way it handles the
      Message 32 of 32 , Feb 6, 2003
      • 0 Attachment
        Glenn Maynard wrote:

        > > Can you check the changes for enc_codepage and send me a patch again?
        > > Preferably against the current version with the Unicode clipboard patch
        > > included.
        >
        > I'll run over it and send it again. It'd be easiest if you could commit
        > the clipboard patch to CVS, so I can diff from there.

        That has a catch 42 problem: I would like to test the whole thing before
        sending the patch into the world.

        > > I'm actually more worried about plain mistakes in the code. I did some
        > > cleaning up and could not test it all.
        >
        > I got it to apply (along with the strlen fix), and it's worked in a few
        > cursory tests (copying and pasting JP text with enc=utf-8 and enc=cp932).
        > I suspect you'll want more testing in 9x, which I can't do here ...

        I didn't change the way it handles the clipboard. It's mostly the
        various conversions that need to be checked, including iconv().

        --
        hundred-and-one symptoms of being an internet addict:
        156. You forget your friend's name but not her e-mail address.

        /// 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.