GNU bug report logs - #23519
25.0.93; pasting with the middle mouse button while searching doesn't work

Previous Next

Package: emacs;

Reported by: jsynacek <at> redhat.com (Jan Synáček)

Date: Thu, 12 May 2016 07:29:01 UTC

Severity: normal

Found in version 25.0.93

Done: Paul Eggert <eggert <at> cs.ucla.edu>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 23519 in the body.
You can then email your comments to 23519 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#23519; Package emacs. (Thu, 12 May 2016 07:29:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to jsynacek <at> redhat.com (Jan Synáček):
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Thu, 12 May 2016 07:29:01 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: jsynacek <at> redhat.com (Jan Synáček)
To: bug-gnu-emacs <at> gnu.org
Subject: 25.0.93;
 pasting with the middle mouse button while searching doesn't work
Date: Thu, 12 May 2016 09:28:03 +0200
1) emacs -Q -nw <file> (reproduces even without -nw)
2) C-s
3) Have some text selected and click the middle mouse button.

The selected text is pasted into the buffer, not the minibuffer. Here is
what I see in lossage:

C-s [isearch-forward]
ESC [ 2 0 0 ~ [xterm-paste]
r s y n c ESC [ 2 0 1 ~ C-h l [view-lossage]

This is a regression from Emacs 24.5.



In GNU Emacs 25.0.93.1 (x86_64-redhat-linux-gnu, GTK+ Version 3.20.3)
 of 2016-05-03 built on jsynacek-ntb
Windowing system distributor 'Fedora Project', version 11.0.11803000
System Description:	Fedora release 24 (Twenty Four)

Configured using:
 'configure --build=x86_64-redhat-linux-gnu
 --host=x86_64-redhat-linux-gnu --program-prefix=
 --disable-dependency-tracking --prefix=/usr --exec-prefix=/usr
 --bindir=/usr/bin --sbindir=/usr/sbin --sysconfdir=/etc
 --datadir=/usr/share --includedir=/usr/include --libdir=/usr/lib64
 --libexecdir=/usr/libexec --localstatedir=/var
 --sharedstatedir=/var/lib --mandir=/usr/share/man
 --infodir=/usr/share/info --with-dbus --with-gif --with-jpeg --with-png
 --with-rsvg --with-tiff --with-xft --with-xpm --with-x-toolkit=gtk3
 --with-gpm=no --with-xwidgets build_alias=x86_64-redhat-linux-gnu
 host_alias=x86_64-redhat-linux-gnu 'CFLAGS=-DMAIL_USE_LOCKF -O2 -g
 -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2
 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4
 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1
 -m64 -mtune=generic' LDFLAGS=-Wl,-z,relro
 PKG_CONFIG_PATH=:/usr/lib64/pkgconfig:/usr/share/pkgconfig'

Configured features:
XPM JPEG TIFF GIF PNG RSVG IMAGEMAGICK SOUND DBUS GCONF GSETTINGS NOTIFY
ACL LIBSELINUX GNUTLS LIBXML2 FREETYPE M17N_FLT LIBOTF XFT ZLIB
TOOLKIT_SCROLL_BARS GTK3 X11 XWIDGETS

Important settings:
  value of $LANG: en_US.UTF-8
  value of $XMODIFIERS: @im=ibus
  locale-coding-system: utf-8-unix

Major mode: Haskell

Minor modes in effect:
  global-auto-revert-mode: t
  global-git-commit-mode: t
  async-bytecomp-package-mode: t
  diff-auto-refine-mode: t
  haskell-indentation-mode: t
  erc-notifications-mode: t
  shell-dirtrack-mode: t
  erc-list-mode: t
  erc-menu-mode: t
  erc-autojoin-mode: t
  erc-ring-mode: t
  erc-networks-mode: t
  erc-pcomplete-mode: t
  erc-track-mode: t
  erc-track-minor-mode: t
  erc-match-mode: t
  erc-button-mode: t
  erc-fill-mode: t
  erc-stamp-mode: t
  erc-netsplit-mode: t
  erc-irccontrols-mode: t
  erc-noncommands-mode: t
  erc-move-to-prompt-mode: t
  erc-readonly-mode: t
  recentf-mode: t
  override-global-mode: t
  show-paren-mode: t
  tooltip-mode: t
  global-eldoc-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  column-number-mode: t
  line-number-mode: t
  transient-mark-mode: t

Recent messages:
<redacted>

Load-path shadows:
/home/jsynacek/.emacs.d/elpa/helm-20160202.843/helm-multi-match hides /home/jsynacek/.emacs.d/elpa/helm-core-20160201.100/helm-multi-match

Features:
(shadow sort mail-extr emacsbug sendmail align linum magit-blame
magit-stash magit-bisect magit-remote magit-commit magit-sequence magit
magit-apply magit-wip magit-log magit-diff smerge-mode magit-core
magit-autorevert autorevert filenotify magit-process magit-popup
magit-mode magit-git crm magit-section magit-utils git-commit log-edit
message idna rfc822 mml mml-sec epg mm-decode mm-bodies mm-encode
mail-parse rfc2231 rfc2047 rfc2045 ietf-drums mailabbrev mail-utils
gmm-utils mailheader pcvs-util add-log with-editor async-bytecomp async
tramp-sh server dash hippie-exp vc-git diff-mode sh-script smie
executable derived rpm-spec-mode undo-tree diff misearch multi-isearch
haskell-doc inf-haskell haskell-decl-scan imenu haskell
haskell-completions haskell-load haskell-commands highlight-uses-mode
haskell-modules haskell-sandbox haskell-repl haskell-debug
haskell-interactive-mode haskell-presentation-mode haskell-collapse
haskell-navigate-imports haskell-compile haskell-hoogle haskell-process
haskell-session json map haskell-mode haskell-font-lock
haskell-indentation haskell-string haskell-sort-imports haskell-lexeme
haskell-align-imports haskell-compat haskell-complete-module noutline
outline flymake etags xref project dabbrev haskell-cabal haskell-utils
haskell-customize ido tramp-cache erc-desktop-notifications
notifications dbus winner helm-command helm-elisp helm-eval edebug
helm-mode helm-files rx image-dired tramp tramp-compat tramp-loaddefs
trampver ucs-normalize shell dired-aux ffap helm-buffers helm-elscreen
helm-tags helm-bookmark helm-adaptive helm-info bookmark helm-locate
helm-external helm-net browse-url xml url url-proxy url-privacy
url-expand url-methods url-history url-cookie url-domsuf url-util
url-parse url-vars mailcap helm-types private erc-list erc-menu erc-join
erc-ring erc-networks erc-pcomplete pcomplete erc-track erc-match
erc-button erc-fill erc-stamp erc-netsplit erc-goodies erc erc-backend
erc-compat format-spec auth-source gnus-util mm-util help-fns mail-prsvr
password-cache thingatpt pp helm-swoop helm-grep helm-regexp helm-plugin
helm-utils compile comint ansi-color ring helm-help helm helm-source
cl-seq eieio-compat eieio eieio-core cl-macs helm-multi-match helm-lib
geiser recentf tree-widget wid-edit edmacro kmacro dired-x dired cc-mode
cc-fonts cc-guess cc-menus cc-cmds cc-styles cc-align cc-engine cc-vars
cc-defs use-package diminish bind-key easy-mmode advice finder-inf
goto-chg-autoloads undo-tree-autoloads info package epg-config seq
byte-opt gv bytecomp byte-compile cl-extra help-mode easymenu cconv
cl-loaddefs pcase cl-lib paren time-date mule-util tooltip eldoc
electric uniquify ediff-hook vc-hooks lisp-float-type mwheel x-win
term/common-win x-dnd tool-bar dnd fontset image regexp-opt fringe
tabulated-list newcomment elisp-mode lisp-mode prog-mode register page
menu-bar rfn-eshadow timer select scroll-bar mouse jit-lock font-lock
syntax facemenu font-core frame cl-generic cham georgian utf-8-lang
misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms
cp51932 hebrew greek romanian slovak czech european ethiopic indian
cyrillic chinese charscript case-table epa-hook jka-cmpr-hook help
simple abbrev minibuffer cl-preloaded nadvice loaddefs button faces
cus-face macroexp files text-properties overlay sha1 md5 base64 format
env code-pages mule custom widget hashtable-print-readable backquote
dbusbind inotify dynamic-setting system-font-setting font-render-setting
xwidget-internal move-toolbar gtk x-toolkit x multi-tty
make-network-process emacs)

Memory information:
((conses 16 755528 110849)
 (symbols 48 44955 0)
 (miscs 40 304 1993)
 (strings 32 108614 21710)
 (string-bytes 1 3127236)
 (vectors 16 77284)
 (vector-slots 8 2054196 158754)
 (floats 8 521 702)
 (intervals 56 26890 825)
 (buffers 976 36)
 (heap 1024 67884 3877))

-- 
Jan Synacek
Software Engineer, Red Hat




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#23519; Package emacs. (Thu, 12 May 2016 08:01:02 GMT) Full text and rfc822 format available.

Message #8 received at 23519 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: jsynacek <at> redhat.com (Jan Synáček)
Cc: 23519 <at> debbugs.gnu.org
Subject: Re: bug#23519: 25.0.93;
 pasting with the middle mouse button while searching doesn't work
Date: Thu, 12 May 2016 11:00:00 +0300
> From: jsynacek <at> redhat.com (Jan Synáček)
> Date: Thu, 12 May 2016 09:28:03 +0200
> 
> 
> 1) emacs -Q -nw <file> (reproduces even without -nw)

Please show lossage in a GUI session, as mouse handling is very
different there.

> 2) C-s
> 3) Have some text selected and click the middle mouse button.
> 
> The selected text is pasted into the buffer, not the minibuffer.

I cannot reproduce this here in a GUI session: as long as I have the
mouse pointer in the minibuffer when I press mouse-2, the selected
text is pasted into the minibuffer, and Emacs does search for the text
I pasted.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#23519; Package emacs. (Thu, 12 May 2016 08:05:01 GMT) Full text and rfc822 format available.

Message #11 received at 23519 <at> debbugs.gnu.org (full text, mbox):

From: Jan Synacek <jsynacek <at> redhat.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 23519 <at> debbugs.gnu.org
Subject: Re: bug#23519: 25.0.93; pasting with the middle mouse button while
 searching doesn't work
Date: Thu, 12 May 2016 10:04:29 +0200
On Thu, May 12, 2016 at 10:00 AM, Eli Zaretskii <eliz <at> gnu.org> wrote:
>> From: jsynacek <at> redhat.com (Jan Synáček)
>> Date: Thu, 12 May 2016 09:28:03 +0200
>>
>>
>> 1) emacs -Q -nw <file> (reproduces even without -nw)
>
> Please show lossage in a GUI session, as mouse handling is very
> different there.
>> 2) C-s
>> 3) Have some text selected and click the middle mouse button.
>>
>> The selected text is pasted into the buffer, not the minibuffer.
>
> I cannot reproduce this here in a GUI session: as long as I have the
> mouse pointer in the minibuffer when I press mouse-2, the selected
> text is pasted into the minibuffer, and Emacs does search for the text
> I pasted.

I was probably too quick with testing. It works in a GUI session,
sorry about the noise. But still doesn't work with -nw, but used to in 24.5.

-- 
Jan Synacek
Software Engineer, Red Hat




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#23519; Package emacs. (Thu, 12 May 2016 08:24:01 GMT) Full text and rfc822 format available.

Message #14 received at 23519 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Jan Synacek <jsynacek <at> redhat.com>
Cc: 23519 <at> debbugs.gnu.org
Subject: Re: bug#23519: 25.0.93; pasting with the middle mouse button while
 searching doesn't work
Date: Thu, 12 May 2016 11:23:33 +0300
> Date: Thu, 12 May 2016 10:04:29 +0200
> From: Jan Synacek <jsynacek <at> redhat.com>
> Cc: 23519 <at> debbugs.gnu.org
> 
> I was probably too quick with testing. It works in a GUI session,
> sorry about the noise. But still doesn't work with -nw, but used to in 24.5.

Does your xterm support the "bracketed paste mode"?  Does Emacs enable
it automatically at startup?




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#23519; Package emacs. (Thu, 12 May 2016 08:44:02 GMT) Full text and rfc822 format available.

Message #17 received at 23519 <at> debbugs.gnu.org (full text, mbox):

From: Jan Synacek <jsynacek <at> redhat.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 23519 <at> debbugs.gnu.org
Subject: Re: bug#23519: 25.0.93; pasting with the middle mouse button while
 searching doesn't work
Date: Thu, 12 May 2016 10:42:57 +0200
On Thu, May 12, 2016 at 10:23 AM, Eli Zaretskii <eliz <at> gnu.org> wrote:
>> Date: Thu, 12 May 2016 10:04:29 +0200
>> From: Jan Synacek <jsynacek <at> redhat.com>
>> Cc: 23519 <at> debbugs.gnu.org
>>
>> I was probably too quick with testing. It works in a GUI session,
>> sorry about the noise. But still doesn't work with -nw, but used to in 24.5.
>
> Does your xterm support the "bracketed paste mode"?  Does Emacs enable
> it automatically at startup?

Probably? I also tested both 24.5 and 25.0.93 in a gnome-terminal
window on Fedora 23. The stable version works, the pretest doesn't.

-- 
Jan Synacek
Software Engineer, Red Hat




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#23519; Package emacs. (Thu, 12 May 2016 09:04:02 GMT) Full text and rfc822 format available.

Message #20 received at 23519 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Jan Synacek <jsynacek <at> redhat.com>
Cc: 23519 <at> debbugs.gnu.org
Subject: Re: bug#23519: 25.0.93; pasting with the middle mouse button while
 searching doesn't work
Date: Thu, 12 May 2016 12:03:16 +0300
> Date: Thu, 12 May 2016 10:42:57 +0200
> From: Jan Synacek <jsynacek <at> redhat.com>
> Cc: 23519 <at> debbugs.gnu.org
> 
> On Thu, May 12, 2016 at 10:23 AM, Eli Zaretskii <eliz <at> gnu.org> wrote:
> >> Date: Thu, 12 May 2016 10:04:29 +0200
> >> From: Jan Synacek <jsynacek <at> redhat.com>
> >> Cc: 23519 <at> debbugs.gnu.org
> >>
> >> I was probably too quick with testing. It works in a GUI session,
> >> sorry about the noise. But still doesn't work with -nw, but used to in 24.5.
> >
> > Does your xterm support the "bracketed paste mode"?  Does Emacs enable
> > it automatically at startup?
> 
> Probably? I also tested both 24.5 and 25.0.93 in a gnome-terminal
> window on Fedora 23. The stable version works, the pretest doesn't.

What do you see in lossage in the version that does work?




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#23519; Package emacs. (Mon, 16 May 2016 08:17:02 GMT) Full text and rfc822 format available.

Message #23 received at 23519 <at> debbugs.gnu.org (full text, mbox):

From: Jan Synacek <jsynacek <at> redhat.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 23519 <at> debbugs.gnu.org
Subject: Re: bug#23519: 25.0.93; pasting with the middle mouse button while
 searching doesn't work
Date: Mon, 16 May 2016 10:16:35 +0200
On Thu, May 12, 2016 at 11:03 AM, Eli Zaretskii <eliz <at> gnu.org> wrote:
>> Date: Thu, 12 May 2016 10:42:57 +0200
>> From: Jan Synacek <jsynacek <at> redhat.com>
>> Cc: 23519 <at> debbugs.gnu.org
>>
>> On Thu, May 12, 2016 at 10:23 AM, Eli Zaretskii <eliz <at> gnu.org> wrote:
>> >> Date: Thu, 12 May 2016 10:04:29 +0200
>> >> From: Jan Synacek <jsynacek <at> redhat.com>
>> >> Cc: 23519 <at> debbugs.gnu.org
>> >>
>> >> I was probably too quick with testing. It works in a GUI session,
>> >> sorry about the noise. But still doesn't work with -nw, but used to in 24.5.
>> >
>> > Does your xterm support the "bracketed paste mode"?  Does Emacs enable
>> > it automatically at startup?
>>
>> Probably? I also tested both 24.5 and 25.0.93 in a gnome-terminal
>> window on Fedora 23. The stable version works, the pretest doesn't.
>
> What do you see in lossage in the version that does work?

Emacs 24.5.1 (works):

C-s j s y n a c e k RET C-h l

The RET is pressed by me, not inserted when pasting.


Emacs 25.0.93.1 (doesn't work):

C-s [isearch-forward]
ESC [ 2 0 0 ~ [xterm-paste]
j s y n a c e k ESC [ 2 0 1 ~ C-h l [view-lossage]

-- 
Jan Synacek
Software Engineer, Red Hat




Added indication that bug 23519 blocks19759 Request was from Glenn Morris <rgm <at> gnu.org> to control <at> debbugs.gnu.org. (Mon, 16 May 2016 17:25:02 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#23519; Package emacs. (Wed, 18 May 2016 20:14:02 GMT) Full text and rfc822 format available.

Message #28 received at 23519 <at> debbugs.gnu.org (full text, mbox):

From: Kaushal Modi <kaushal.modi <at> gmail.com>
To: 23519 <at> debbugs.gnu.org, Stefan Monnier <monnier <at> iro.umontreal.ca>
Cc: Eli Zaretskii <eliz <at> gnu.org>
Subject: 25.0.93;
 pasting with the middle mouse button while searching doesn't work
Date: Wed, 18 May 2016 20:13:41 +0000
[Message part 1 (text/plain, inline)]
This seems to have been caused due to this commit:
http://git.savannah.gnu.org/cgit/emacs.git/commit/?h=emacs-25&id=0a21b26c58a241ac41cd12cd10cd605238bb2640

Relevant portion from the diff:

+    ;; Recognize the start of a bracketed paste sequence.  The handler
+    ;; internally recognizes the end.
+    (define-key map "\e[200~" [xterm-paste])

Copying Stefan as he authored that commit.
-- 

-- 
Kaushal Modi
[Message part 2 (text/html, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#23519; Package emacs. (Thu, 19 May 2016 00:47:02 GMT) Full text and rfc822 format available.

Message #31 received at 23519 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Monnier <monnier <at> IRO.UMontreal.CA>
To: Kaushal Modi <kaushal.modi <at> gmail.com>
Cc: Eli Zaretskii <eliz <at> gnu.org>, 23519 <at> debbugs.gnu.org
Subject: Re: 25.0.93;
 pasting with the middle mouse button while searching doesn't work
Date: Wed, 18 May 2016 20:46:49 -0400
> This seems to have been caused due to this commit:
> http://git.savannah.gnu.org/cgit/emacs.git/commit/?h=emacs-25&id=0a21b26c58a241ac41cd12cd10cd605238bb2640

> Relevant portion from the diff:

> +    ;; Recognize the start of a bracketed paste sequence.  The handler
> +    ;; internally recognizes the end.
> +    (define-key map "\e[200~" [xterm-paste])

> Copying Stefan as he authored that commit.

In previous Emacsen, middle-button would be handled by the terminal
emulator which would end up sending the selection as if you had typed
those chars (so they'd sometimes be interpreted as key-combos).

Now we use a special mode in the terminal emulator which means the
terminal emulator actually tells us that it's a "paste" operation.

So the problem is that isearch currently doesn't have a binding for
xterm-paste.  We should add one, just like we added one to global-map.


        Stefan




Reply sent to Paul Eggert <eggert <at> cs.ucla.edu>:
You have taken responsibility. (Sun, 22 May 2016 20:50:02 GMT) Full text and rfc822 format available.

Notification sent to jsynacek <at> redhat.com (Jan Synáček):
bug acknowledged by developer. (Sun, 22 May 2016 20:50:02 GMT) Full text and rfc822 format available.

Message #36 received at 23519-done <at> debbugs.gnu.org (full text, mbox):

From: Paul Eggert <eggert <at> cs.ucla.edu>
To: Stefan Monnier <monnier <at> IRO.UMontreal.CA>
Cc: Eli Zaretskii <eliz <at> gnu.org>, Jan Synacek <jsynacekf <at> redhat.com>,
 23519-done <at> debbugs.gnu.org, Kaushal Modi <kaushal.modi <at> gmail.com>
Subject: Re: 25.0.93; pasting with the middle mouse button while searching
 doesn't work
Date: Sun, 22 May 2016 13:49:40 -0700
[Message part 1 (text/plain, inline)]
> isearch currently doesn't have a binding for
> xterm-paste.  We should add one, just like we added one to global-map.

Thanks, I did that by installing the attached patch into the emacs-25 branch.
[0001-Bring-back-xterm-pasting-with-middle-mouse.patch (text/x-diff, attachment)]

Removed indication that bug 23519 blocks Request was from Eli Zaretskii <eliz <at> gnu.org> to control <at> debbugs.gnu.org. (Mon, 23 May 2016 02:30:01 GMT) Full text and rfc822 format available.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Mon, 20 Jun 2016 11:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 7 years and 302 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.