annoying PasteStart/PasteEnd

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
14 messages Options
Reply | Threaded
Open this post in threaded view
|

annoying PasteStart/PasteEnd

Johannes-Maria Kaltenbach
Hello,

I just updated vim from 8.0.197 to 8.0.222 and now I
always get a very annoying <PasteStart> before and
<PasteEnd> after anything I paste with the mouse
(middle button) in an xterm on Unix (BSD).
How can I get rid of this 'feature'?

Best regards,
Johannes-Maria


--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: annoying PasteStart/PasteEnd

Christian Brabandt
Hi Johannes-Maria!

On Mo, 23 Jan 2017, Johannes-Maria Kaltenbach wrote:

> Hello,
>
> I just updated vim from 8.0.197 to 8.0.222 and now I
> always get a very annoying <PasteStart> before and
> <PasteEnd> after anything I paste with the mouse
> (middle button) in an xterm on Unix (BSD).
> How can I get rid of this 'feature'?

Patch 210 added bracketed paste support to Vim. It's likely something
isn't working for you. To disable this feature do:
:set t_BE=

This is only a workaround, but I don't know why you would get
<PasteStart>/<PasteEnd> markers. Are you possibly using a bracketed
paste plugin?

Best,
Christian
--
Offen steht das Grab! Welch herrlich Wunder!
Der Herr ist auferstanden! - Wer's glaubt!
Schelmen, ihr trugt ihn ja weg.
                -- Johann Wolfgang von Goethe (Epigramme)

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: annoying PasteStart/PasteEnd

Johannes-Maria Kaltenbach
Hi Christian,

On Mon, Jan 23, 2017 at 02:10:08PM +0100, Christian Brabandt wrote:
> > I just updated vim from 8.0.197 to 8.0.222 and now I
> > always get a very annoying <PasteStart> before and
> > <PasteEnd> after anything I paste with the mouse
> > (middle button) in an xterm on Unix (BSD).
> > How can I get rid of this 'feature'?
>
> Patch 210 added bracketed paste support to Vim. It's likely something
> isn't working for you. To disable this feature do:
> :set t_BE=

Thanks, this helped.

[FYI: it had no effect when given directly in the vim-session
as an ex-command :set t_BE=, but when I added it to my ~/.exrc.]

> This is only a workaround, but I don't know why you would get
> <PasteStart>/<PasteEnd> markers. Are you possibly using a bracketed
> paste plugin?

no; and removing all plugins didn't change this behaviour.


Thanks very much,
Johannes-Maria



--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: annoying PasteStart/PasteEnd

Bram Moolenaar
In reply to this post by Johannes-Maria Kaltenbach

Johannes-Maria Kaltenbach wrote:

> I just updated vim from 8.0.197 to 8.0.222 and now I
> always get a very annoying <PasteStart> before and
> <PasteEnd> after anything I paste with the mouse
> (middle button) in an xterm on Unix (BSD).
> How can I get rid of this 'feature'?

Support for bracketed paste was added, it is supposed to make paste work
better.

I cannot see the problem.  Can you say what exactly you do?
What is your 'mouse' setting?

--
   LAUNCELOT leaps into SHOT with a mighty cry and runs the GUARD through and
   hacks him to the floor.  Blood.  Swashbuckling music (perhaps).
   LAUNCELOT races through into the castle screaming.
SECOND SENTRY: Hey!
                 "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD

 /// Bram Moolenaar -- [hidden email] -- 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    ///

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: annoying PasteStart/PasteEnd

Johannes-Maria Kaltenbach
On Mon, Jan 23, 2017 at 08:46:16PM +0100, Bram Moolenaar wrote:

>
> Johannes-Maria Kaltenbach wrote:
>
> > I just updated vim from 8.0.197 to 8.0.222 and now I
> > always get a very annoying <PasteStart> before and
> > <PasteEnd> after anything I paste with the mouse
> > (middle button) in an xterm on Unix (BSD).
> > How can I get rid of this 'feature'?
>
> Support for bracketed paste was added, it is supposed to make paste work
> better.
>
> I cannot see the problem.  Can you say what exactly you do?
> What is your 'mouse' setting?

no setting.
('verbose set mouse' just returns 'mouse='.)

I don't use gvim, only vim in an xterm.
and just use the mouse as usual in X windows.

When I yank something (left mouse butten), e. g. 'xxx',
and paste it (with the middle mouse butten) then the xxx
is surrounded by <PasteStart> and <PasteEnd>:

        <PasteStart>xxx<PasteEnd>

I've got rid of this with Christian's help by adding
'set t_BE=' to my .exrc.


I only found out today that this occurs only in the
command line (:) or search (/, ?), not when writing
to the buffer.

Best regards,
Johannes-Maria


--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: annoying PasteStart/PasteEnd

Bram Moolenaar

Johannes-Maria Kaltenbach wrote:

> > > I just updated vim from 8.0.197 to 8.0.222 and now I
> > > always get a very annoying <PasteStart> before and
> > > <PasteEnd> after anything I paste with the mouse
> > > (middle button) in an xterm on Unix (BSD).
> > > How can I get rid of this 'feature'?
> >
> > Support for bracketed paste was added, it is supposed to make paste work
> > better.
> >
> > I cannot see the problem.  Can you say what exactly you do?
> > What is your 'mouse' setting?
>
> no setting.
> ('verbose set mouse' just returns 'mouse='.)
>
> I don't use gvim, only vim in an xterm.
> and just use the mouse as usual in X windows.
>
> When I yank something (left mouse butten), e. g. 'xxx',
> and paste it (with the middle mouse butten) then the xxx
> is surrounded by <PasteStart> and <PasteEnd>:
>
>         <PasteStart>xxx<PasteEnd>
>
> I've got rid of this with Christian's help by adding
> 'set t_BE=' to my .exrc.
>
>
> I only found out today that this occurs only in the
> command line (:) or search (/, ?), not when writing
> to the buffer.

Whatever I try I cannot reproduce it.

Does this still happen when you start Vim with:

        vim -u NONE -N

When not resetting t_BE, of course.

--
Futility Factor: No experiment is ever a complete failure - it can always
serve as a negative example.

 /// Bram Moolenaar -- [hidden email] -- 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    ///

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: annoying PasteStart/PasteEnd

Johannes-Maria Kaltenbach
On Tue, Jan 24, 2017 at 02:51:00PM +0100, Bram Moolenaar wrote:

>
> Johannes-Maria Kaltenbach wrote:
>
> > > > I just updated vim from 8.0.197 to 8.0.222 and now I
> > > > always get a very annoying <PasteStart> before and
> > > > <PasteEnd> after anything I paste with the mouse
> > > > (middle button) in an xterm on Unix (BSD).
> > > > How can I get rid of this 'feature'?
> > >
> > > Support for bracketed paste was added, it is supposed to make paste work
> > > better.
> > >
> > > I cannot see the problem.  Can you say what exactly you do?
> > > What is your 'mouse' setting?
> >
> > no setting.
> > ('verbose set mouse' just returns 'mouse='.)
> >
> > I don't use gvim, only vim in an xterm.
> > and just use the mouse as usual in X windows.
> >
> > When I yank something (left mouse butten), e. g. 'xxx',
> > and paste it (with the middle mouse butten) then the xxx
> > is surrounded by <PasteStart> and <PasteEnd>:
> >
> >         <PasteStart>xxx<PasteEnd>
> >
> > I've got rid of this with Christian's help by adding
> > 'set t_BE=' to my .exrc.
> >
> >
> > I only found out today that this occurs only in the
> > command line (:) or search (/, ?), not when writing
> > to the buffer.
>
> Whatever I try I cannot reproduce it.
>
> Does this still happen when you start Vim with:
>
> vim -u NONE -N
>
> When not resetting t_BE, of course.

yes


Best regards,
Johannes-Maria


--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: annoying PasteStart/PasteEnd

François Ingelrest
On 24 January 2017 at 15:02, Johannes-Maria Kaltenbach
<[hidden email]> wrote:
>> Whatever I try I cannot reproduce it.
>>
>> Does this still happen when you start Vim with:
>>
>>       vim -u NONE -N
>>
>> When not resetting t_BE, of course.
>
> yes

I've just updated vim to 8.226 and get the same issue. Works fine in
the buffer window, but not in the command line. This is with Vim
running in a gnome terminal.

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: annoying PasteStart/PasteEnd

Tom Snee
In reply to this post by Bram Moolenaar
On Tuesday, January 24, 2017 at 8:51:08 AM UTC-5, Bram Moolenaar wrote:
> Does this still happen when you start Vim with:
>
> vim -u NONE -N
>
> When not resetting t_BE, of course.

It happens for me, but only when I paste in command line mode. Changing t_BE makes no difference. I use Jonathon Fernyhough's Ubuntu vim as described at https://launchpad.net/~jonathonf/+archive/ubuntu/vim

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: annoying PasteStart/PasteEnd

Bram Moolenaar
In reply to this post by Johannes-Maria Kaltenbach

Johannes-Maria Kaltenbach wrote:

> > > > > I just updated vim from 8.0.197 to 8.0.222 and now I
> > > > > always get a very annoying <PasteStart> before and
> > > > > <PasteEnd> after anything I paste with the mouse
> > > > > (middle button) in an xterm on Unix (BSD).
> > > > > How can I get rid of this 'feature'?
> > > >
> > > > Support for bracketed paste was added, it is supposed to make paste work
> > > > better.
> > > >
> > > > I cannot see the problem.  Can you say what exactly you do?
> > > > What is your 'mouse' setting?
> > >
> > > no setting.
> > > ('verbose set mouse' just returns 'mouse='.)
> > >
> > > I don't use gvim, only vim in an xterm.
> > > and just use the mouse as usual in X windows.
> > >
> > > When I yank something (left mouse butten), e. g. 'xxx',
> > > and paste it (with the middle mouse butten) then the xxx
> > > is surrounded by <PasteStart> and <PasteEnd>:
> > >
> > >         <PasteStart>xxx<PasteEnd>
> > >
> > > I've got rid of this with Christian's help by adding
> > > 'set t_BE=' to my .exrc.
> > >
> > >
> > > I only found out today that this occurs only in the
> > > command line (:) or search (/, ?), not when writing
> > > to the buffer.
> >
> > Whatever I try I cannot reproduce it.
> >
> > Does this still happen when you start Vim with:
> >
> > vim -u NONE -N
> >
> > When not resetting t_BE, of course.
>
> yes

Found it: part of the change was missing from the patch.
So it worked for me but nobody else.

--
I still remember when I gave up Smoking, Drinking and Sex.  It was the
most *horrifying* hour of my life!

 /// Bram Moolenaar -- [hidden email] -- 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    ///

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: annoying PasteStart/PasteEnd

Johannes-Maria Kaltenbach
On Tue, Jan 24, 2017 at 03:58:14PM +0100, Bram Moolenaar wrote:
> Found it: part of the change was missing from the patch.
> So it worked for me but nobody else.

Thanks.
I've updated now to vim-8.0.237 and it works fine.

Best regards,
Johannes-Maria


--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: annoying PasteStart/PasteEnd

Johannes-Maria Kaltenbach
In reply to this post by Johannes-Maria Kaltenbach
On Wed, Jan 25, 2017 at 01:53:54PM +0100, Johannes-Maria Kaltenbach wrote:
> On Tue, Jan 24, 2017 at 03:58:14PM +0100, Bram Moolenaar wrote:
> > Found it: part of the change was missing from the patch.
> > So it worked for me but nobody else.
>
> Thanks.
> I've updated now to vim-8.0.237 and it works fine.

but (at least for me) it is better to keep 'set t_BE=' in the
configuration file. The <PasteStart>/<PasteEnd> around pasted
text is gone but if one yanks a whole line (or part of the line
until the end of the line) with the mouse and pastes it in an
xterm then the pasted text contains a ^M at the end instead
of executing a 'return' (as was the old behaviour and the one
I prefer instead of first deleting the ^M and then pressing
return).
[Only in command line (including searches), not while inserting
in buffer.]

Best regards,
Johannes-Maria



--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: annoying PasteStart/PasteEnd

Bram Moolenaar

Johannes-Maria Kaltenbach wrote:

> On Wed, Jan 25, 2017 at 01:53:54PM +0100, Johannes-Maria Kaltenbach wrote:
> > On Tue, Jan 24, 2017 at 03:58:14PM +0100, Bram Moolenaar wrote:
> > > Found it: part of the change was missing from the patch.
> > > So it worked for me but nobody else.
> >
> > Thanks.
> > I've updated now to vim-8.0.237 and it works fine.
>
> but (at least for me) it is better to keep 'set t_BE=' in the
> configuration file. The <PasteStart>/<PasteEnd> around pasted
> text is gone but if one yanks a whole line (or part of the line
> until the end of the line) with the mouse and pastes it in an
> xterm then the pasted text contains a ^M at the end instead
> of executing a 'return' (as was the old behaviour and the one
> I prefer instead of first deleting the ^M and then pressing
> return).
> [Only in command line (including searches), not while inserting
> in buffer.]

I assume you are talking about the command line, or entering search.
Yes, it's intentional that the line break does not work like pressing
Enter.  The idea is that you are pasting text, not a command.
You are supposed to view the text before deciding to execute it.
The thread that started it mentioned that the source of the text may
give you something else than what you expected.  In practice, what often
happens is that you accidentally copy the wrong text and include the
line break when that is not intended.

--
ARTHUR:  Be quiet!
DENNIS:  --but by a two-thirds majority in the case of more--
ARTHUR:  Be quiet!  I order you to be quiet!
WOMAN:   Order, eh -- who does he think he is?
ARTHUR:  I am your king!
                                  The Quest for the Holy Grail (Monty Python)

 /// Bram Moolenaar -- [hidden email] -- 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    ///

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: annoying PasteStart/PasteEnd

Johannes-Maria Kaltenbach
On Thu, Jan 26, 2017 at 08:40:27PM +0100, Bram Moolenaar wrote:

>
> Johannes-Maria Kaltenbach wrote:
>
> > On Wed, Jan 25, 2017 at 01:53:54PM +0100, Johannes-Maria Kaltenbach wrote:
> > > On Tue, Jan 24, 2017 at 03:58:14PM +0100, Bram Moolenaar wrote:
> > > > Found it: part of the change was missing from the patch.
> > > > So it worked for me but nobody else.
> > >
> > > Thanks.
> > > I've updated now to vim-8.0.237 and it works fine.
> >
> > but (at least for me) it is better to keep 'set t_BE=' in the
> > configuration file. The <PasteStart>/<PasteEnd> around pasted
> > text is gone but if one yanks a whole line (or part of the line
> > until the end of the line) with the mouse and pastes it in an
> > xterm then the pasted text contains a ^M at the end instead
> > of executing a 'return' (as was the old behaviour and the one
> > I prefer instead of first deleting the ^M and then pressing
> > return).
> > [Only in command line (including searches), not while inserting
> > in buffer.]
>
> I assume you are talking about the command line, or entering search.

yes, both.

> Yes, it's intentional that the line break does not work like pressing
> Enter.  The idea is that you are pasting text, not a command.

OK, so in the case of the end-of-line it was intended.

> You are supposed to view the text before deciding to execute it.
> The thread that started it mentioned that the source of the text may
> give you something else than what you expected.  In practice, what often
> happens is that you accidentally copy the wrong text and include the
> line break when that is not intended.

Personally I prefer like it was in earlier versions
but that's no problem since I can have this with 'set t_BE='.

Thanks,
Johannes-Maria


--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.