unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#20260: 24.4.1; Triple-clicking selects and deselects the line in weird situations
@ 2015-04-04 22:29 Jorgen Schaefer
  2015-04-07 18:53 ` Stefan Monnier
  2015-04-08 10:41 ` Vasilij Schneidermann
  0 siblings, 2 replies; 6+ messages in thread
From: Jorgen Schaefer @ 2015-04-04 22:29 UTC (permalink / raw)
  To: 20260

Hello!
We came across a weird behavior in Emacs.

The graphical version (in X) will select a line if the mouse is
triple-clicked. Under certain situations, it will select but immediately
deselect the line again.

Reproduction:

Triple-click on any line in any buffer. Notice that Emacs selects the
whole line, and leaves it selected.

Evaluate the following code.

(defun repro-filter (fun beg end delete)
  (let ((string (funcall fun beg end delete)))
    (with-temp-buffer
      (insert "."))
    string))

(with-current-buffer (get-buffer-create "*Bug*")
  (set (make-local-variable 'filter-buffer-substring-functions)
       '(repro-filter))
  (insert "Hello, World!\n")
  (pop-to-buffer (current-buffer)))

Triple-click on the "World" in the *Bug* buffer. Notice that Emacs
selects the whole line only momentarily, and then deselects it again
immediately.

I expected the line to stay selected like without this piece of code.

This bug was not present in 24.3.

Regards,
Jorgen





^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2015-04-13 14:18 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-04-04 22:29 bug#20260: 24.4.1; Triple-clicking selects and deselects the line in weird situations Jorgen Schaefer
2015-04-07 18:53 ` Stefan Monnier
2015-04-08 10:41 ` Vasilij Schneidermann
2015-04-08 14:26   ` Stefan Monnier
2015-04-10 19:04     ` Jorgen Schäfer
2015-04-13 14:18     ` Stefan Monnier

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).