Brett Stahlman wrote:
>
> On Nov 5, 3:58 am, SungHyun Nam<[email protected]> wrote:
>>
>> The problem is:
>> 1. run 'gvim -u NONE -U NONE --noplugin somefile'
>> 2. double click string 'AAA' in gvim (any string).
>> 3. paste by clicking middle mouse button on a putty terminal
>> or
>> <C-V> in the notepad
>>
>> ==> 'AAA' pasted. good!
>>
>> 4. double click other string 'BBB' in gvim (any other string).
>> 5. paste on a putty or notepad
>> ==> 'AAA' pasted. err... :-(
>>
>> 6. double click any string in a putty terminal
>> and then double click string 'BBB' in gvim
>> 7. paste on a putty or notepad
>> ==> 'BBB' pasted now. oh! I found a work-around. :)
>
> I think you're experiencing an issue reported some years back:
> http://markmail.org/message/pv34n2ljlkevbs2e#query:clipboard%20stahlman%20Vim+page:1+mid:g3enifjnqmbvbbub+state:results
>
> At that time, I submitted a patch for Vim, but Bram correctly
> pointed out that the fault was really with Cygwin X, so I then
> created a patch for Cygwin X, which was eventually accepted, but
> now has been re- opened...
Because I also have problem for the linux+gvim+gtk (VNC
environment, totally not related to cygwin), I think I should use
your patch for linux+gvim+gtk.
After testing the patch, I found simple patch below fixes both
cygwin and VNC cases.
I'm not sure it's a bug in both CYGWIN/X and VNC. But as I said
previous mail, gnome-terminal works fine in VNC environment. So
that, gnome-terminal always re-owns the selection?
Thanks,
namsh
diff --git a/src/ui.c b/src/ui.c
index df8008c..a26bf8a 100644
--- a/src/ui.c
+++ b/src/ui.c
@@ -467,7 +467,7 @@ clip_own_selection(cbd)
* Also want to check somehow that we are reading from the
keyboard rather
* than a mapping etc.
*/
- if (!cbd->owned && cbd->available)
+ if (cbd->available)
{
cbd->owned = (clip_gen_own_selection(cbd) == OK);
#ifdef FEAT_X11
--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---