Re: Subject: Re: vim on cygwin using win32 clipboard

81 views
Skip to first unread message

Anton Sharonov

unread,
Oct 28, 2008, 9:04:32 PM10/28/08
to vim...@googlegroups.com
On 22 May 2007, Frodak Baksik wrote:
> I've updated the patch to work with version 7.1. Specifically
> the first patch was against version 212 of
> https://svn.sourceforge.net/svnroot/vim/vim7. I checked this
> out, applied the patch, updated to revision 296, and fixed the
> conflicts you mentioned.
>
> Thanks,
> Frodak

I have updated the patch for the vim 7.2 sources (tested cygwin
compilation against revision 1217 of subversion repository
https://vim.svn.sourceforge.net/svnroot/vim/vim7).

Many thanks to Frodak for very useful feature,
Anton.

vim_on_cygwin_using_win32_clipboard_2008_10_29.patch

Gary Johnson

unread,
Oct 28, 2008, 9:37:47 PM10/28/08
to vim...@googlegroups.com

Indeed, and thank you for bringing the patch up to date.

The version of the patch I've been using appears to be from
2007-02-13. It also had some changes to auto/configure that are
missing from your attached patch. Was that intentional?

Is this a patch that we should try to have added to the official
source, or should it remain a patch?

Regards,
Gary

Gary Johnson

unread,
Oct 28, 2008, 9:45:07 PM10/28/08
to vim...@googlegroups.com

I forgot to include this, the output of diffstat run on the patch.


Make_bc5.mak | 2
Make_cyg.mak | 1
Make_ivc.mak | 5
Make_ming.mak | 1
Make_mvc.mak | 4
Make_w16.mak | 1
Makefile | 16
config.h.in | 3
configure.in | 15
feature.h | 5
globals.h | 2
mbyte.c | 6
os_mswin.c | 685 --------------------------------------
os_unix.c | 3
os_win32.c | 22 -
proto.h | 2
proto/os_mswin.pro | 11
proto/winclip.pro | 13
term.c | 2
vim.h | 2
winclip.c | 737 +++++++++++++++++++++++++++++++++++++++++
21 files changed, 815 insertions(+), 723 deletions(-)


Regards,
Gary

Anton Sharonov

unread,
Oct 29, 2008, 4:44:12 AM10/29/08
to vim...@googlegroups.com
On 2008-10-28, Gary Johnson wrote

> The version of the patch I've been using appears to be from
> 2007-02-13.

The most recent version, provided by Frodak Baksik to start with
I have found in his post from 2008-05-22:

http://www.mail-archive.com/vim...@vim.org/msg04154.html
or
http://markmail.org/search/?q=FEAT_CYGWIN_WIN32_CLIPBOARD

It is recent enough for me - at least after minor adoption
(nothing like programming, just stupid helping the patch to find
proper places to modify) to actual vim sources it is working
properly.

> It also had some changes to auto/configure that are
> missing from your attached patch. Was that intentional?

Thanks for pointing that out, it was not intentional. I thought
that auto/configure is just modified during configure process -
the same way as src/auto/config.h, src/auto/config.mk are
overwritten each time I run configure... Updated patch is
attached.

> Is this a patch that we should try to have added to the official
> source, or should it remain a patch?

Unless somebody (Frodak ?) will come with more recent version,
IMO it should be added to the official source. Bram have had the
opinion that few people should try it out and report their
results here (in his http://markmail.org/message/pyfrowvkaksym3vp
post of 02/14/2007 06:30:57). If I count properly, actually ~5
people have already tried that patch and found it worked. Is it
enough ? (All those tests are done only on cygwin platform for
now, IIUC).

Anton.

vim_on_cygwin_using_win32_clipboard_2008_10_29_002.patch

Anton Sharonov

unread,
Dec 22, 2008, 4:17:16 AM12/22/08
to vim...@googlegroups.com
As usual, many thanks to Frodak Baksik for useful feature.

I updated the patch to be compatible with the recent VIM trunk
(tested cygwin compilation against r1296 of SVN). It was broken
after several functions for dealing with Unicode from clipboard
were modified and renamed in trunk:

utf8_to_ucs2 -> utf8_to_utf16
ucs2_to_utf8 -> utf16_to_utf8

enc_to_ucs2 -> enc_to_utf16
ucs2_to_enc -> utf16_to_enc

Now it is fixed. Version of patch, which is to be used for
eventual addition to the official VIM sources:

vim_on_cygwin_using_win32_clipboard__full__2008_12_21_001.patch

This full patch tries to make a little refactoring of the VIM
sources, so that several functions are moved to it's own file
winclip.c (as far as I can remember Frodak has done it on Bram
advise). This "full" patch is however hard to maintain in case
of conflicts, therefore here is simplified version, which has
more chances to "survive" the future VIM changes:

vim_on_cygwin_using_win32_clipboard__simple__2008_12_21_001.patch

Note, that this simple version should be used only as "last
resort", in case of "full" patch cannot be applied without
conflicts any more.

--
Anton

vim_on_cygwin_using_win32_clipboard__full__2008_12_21_001.patch
vim_on_cygwin_using_win32_clipboard__simple__2008_12_21_001.patch

Ken Takata

unread,
Jan 1, 2013, 2:08:12 AM1/1/13
to vim...@googlegroups.com
Hi,

Many thanks to Frodak Baksik and Anton Sharonov for this feature.

I have updated Anton's patches to be applied to the latest version (7.3.762).

Best regards,
Ken Takata

vim_on_cygwin_using_win32_clipboard__full__7.3.762.patch
vim_on_cygwin_using_win32_clipboard__simple__7.3.762.patch

Bram Moolenaar

unread,
Jan 2, 2013, 11:57:05 AM1/2/13
to Ken Takata, vim...@googlegroups.com

Ken Takata wrote:

> Many thanks to Frodak Baksik and Anton Sharonov for this feature.
>
> I have updated Anton's patches to be applied to the latest version
> (7.3.762).

Thanks, I'll update the todo list.

--
A computer without Windows is like a fish without a bicycle.

/// Bram Moolenaar -- Br...@Moolenaar.net -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///

Ken Takata

unread,
Jan 4, 2013, 10:47:42 AM1/4/13
to vim...@googlegroups.com, Ken Takata
Hi,

2013/01/3 Thu 1:57:05 UTC+9 Bram Moolenaar wrote:
> Ken Takata wrote:
>
> > Many thanks to Frodak Baksik and Anton Sharonov for this feature.
> >
> > I have updated Anton's patches to be applied to the latest version
> > (7.3.762).
>
> Thanks, I'll update the todo list.

I have updated the full patch.
"make winclip.pro" didn't work well.

Thanks,
Ken Takata

vim_on_cygwin_using_win32_clipboard__full__7.3.762-2.patch

Ken Takata

unread,
Jan 26, 2013, 11:54:14 AM1/26/13
to vim...@googlegroups.com, Ken Takata
Hi,

I have updated the patches.
There were two problems:

1. (simple version only)
Couldn't compile on Linux with this patch.

2. os_unix.c didn't include winclip.pro or os_mswin.pro.

Thanks,
Ken Takata

vim_on_cygwin_using_win32_clipboard__full__7.3.785.patch
vim_on_cygwin_using_win32_clipboard__simple__7.3.785.patch
Reply all
Reply to author
Forward
0 new messages