From: Juri Linkov <juri@jurta.org>
To: rms@gnu.org
Cc: bug-gnu-emacs@gnu.org, amicitas@gmail.com
Subject: Re: I-search: Clicking in minibuf during I-search fails.
Date: Mon, 22 Oct 2007 03:35:43 +0300 [thread overview]
Message-ID: <87abqc2ibg.fsf@jurta.org> (raw)
In-Reply-To: <E1IjVCw-0000PX-8Y@fencepost.gnu.org> (Richard Stallman's message of "Sun\, 21 Oct 2007 03\:26\:46 -0400")
> This bug is caused by the hack in `isearch-edit-string' that uses
>
> (let ((cursor-in-echo-area t))
> (read-event))
>
> before reading the search string in the minibuffer with
> `read-from-minibuffer'. When clicking mouse-1 in `read-event'
> above, it incorrectly handles the mouse click.
>
> Why does this code handle the mouse-click at all?
> It ought to just return the event, right?
It doesn't read the mouse button release event (mouse-1), so the mouse
release happens in the minibuffer after read-from-minibuffer activates it.
Thus, mouse-1 selects the region because read-from-minibuffer with the
pressed down-mouse-1 puts the mark to the beginning of the minibuffer
(before the prompt).
Below is the test case that emulates this problem in `isearch-edit-string':
(progn
(message "Prompt: ")
(let ((cursor-in-echo-area t))
(read-event))
(read-from-minibuffer "Prompt: "))
after evaluating you can try to press mouse-1 in the echo area,
and release it in the minibuffer.
--
Juri Linkov
http://www.jurta.org/emacs/
next prev parent reply other threads:[~2007-10-22 0:35 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-10 3:16 I-search: Clicking in minibuf during I-search fails amicitas
2007-10-10 13:55 ` Drew Adams
2007-10-10 21:03 ` Richard Stallman
[not found] ` <mailman.1937.1192050272.18990.bug-gnu-emacs@gnu.org>
2007-10-10 21:51 ` amicitas
2007-10-10 23:44 ` Juri Linkov
2007-10-12 2:46 ` Richard Stallman
2007-10-28 14:51 ` Juri Linkov
[not found] ` <mailman.1940.1192060132.18990.bug-gnu-emacs@gnu.org>
2007-10-14 23:34 ` amicitas
2007-10-19 23:52 ` Juri Linkov
2007-10-21 7:26 ` Richard Stallman
2007-10-22 0:35 ` Juri Linkov [this message]
2007-10-23 7:12 ` Richard Stallman
2007-10-23 23:52 ` Juri Linkov
2007-10-24 8:33 ` Richard Stallman
2007-10-24 21:28 ` Juri Linkov
2007-10-25 9:01 ` Richard Stallman
2007-10-26 22:43 ` Juri Linkov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87abqc2ibg.fsf@jurta.org \
--to=juri@jurta.org \
--cc=amicitas@gmail.com \
--cc=bug-gnu-emacs@gnu.org \
--cc=rms@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).