GNU bug report logs -
#71603
Mouse clicking on a list-bookmarks' entry can not jump the cursor
Previous Next
Reported by: Siyuan Chen <chansey97 <at> gmail.com>
Date: Mon, 17 Jun 2024 00:32:02 UTC
Severity: normal
Done: Eli Zaretskii <eliz <at> gnu.org>
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 71603 in the body.
You can then email your comments to 71603 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#71603
; Package
emacs
.
(Mon, 17 Jun 2024 00:32:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Siyuan Chen <chansey97 <at> gmail.com>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Mon, 17 Jun 2024 00:32:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
The reproduce steps:
1. Open Emacs 29.3 on Windows with -Q
2. Open a .el file which included some code, e.g. init.el
3. M-x `bookmark-delete-all` to cleanup bookmarks if you have
4. M-x `bookmark-set` at some locations, e.g. bk1 bk2
5. M-x `list-bookmarks` to open *Bookmark List* which should have 2 entries
6. Split 2 windows, the up window displays init.el, the bottom window
displays *Bookmark List*
7. Mouse left click (or press 'on' ) on bk1 or bk2 in *Bookmark List*
The expected behavior: jump cursor to bk1 or bk2
The actual behavior: nothing happens, except the left fringe displays an
additional bookmark icon if your current point is not at one of the
bookmark locations.
I don't know if this is a bug or the intended behavior, but when I put the
mouse on the bk1 or bk2 entry it will show "mouse-1: go to this bookmark in
other window", so I believe it is a bug.
In addition, if you click the entries via Mouse middle click, i.e. mouse-2,
then it seems to half work with a different weird behavior. Simply traced
the code and found that both invoke
`bookmark-bmenu-other-window-with-mouse` but I don't know why they have
different behaviors.
P.s. I can workaround it via hacking bookmark.el because `bookmark-jump`
works perfectly, but I just want to know if this is a real bug.
Thanks.
Best regards,
Siyuan Chen
[Message part 2 (text/html, inline)]
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#71603
; Package
emacs
.
(Mon, 17 Jun 2024 06:35:01 GMT)
Full text and
rfc822 format available.
Message #8 received at 71603 <at> debbugs.gnu.org (full text, mbox):
Hi there,
Siyuan Chen <chansey97 <at> gmail.com> writes:
> The reproduce steps:
>
> 1. Open Emacs 29.3 on Windows with -Q
>
> 2. Open a .el file which included some code, e.g. init.el
>
> 3. M-x `bookmark-delete-all` to cleanup bookmarks if you have
>
> 4. M-x `bookmark-set` at some locations, e.g. bk1 bk2
>
> 5. M-x `list-bookmarks` to open *Bookmark List* which should have 2 entries
>
> 6. Split 2 windows, the up window displays init.el, the bottom window displays *Bookmark List*
>
> 7. Mouse left click (or press 'on' ) on bk1 or bk2 in *Bookmark List*
>
> The expected behavior: jump cursor to bk1 or bk2
>
> The actual behavior: nothing happens, except the left fringe displays an additional bookmark icon if your current
> point is not at one of the bookmark locations.
Thanks, I can reproduce this issue on master. Does the diff below yield
the expected behavior?
diff --git a/lisp/bookmark.el b/lisp/bookmark.el
index 06f8e24b518..d87d4e473ac 100644
--- a/lisp/bookmark.el
+++ b/lisp/bookmark.el
@@ -1265,10 +1265,11 @@ bookmark--jump-via
by BOOKMARK-NAME-OR-RECORD, if necessary, run `bookmark-after-jump-hook',
and then show any annotations for this bookmark."
(bookmark-handle-bookmark bookmark-name-or-record)
- (save-current-buffer
- (funcall display-function (current-buffer)))
- (let ((win (get-buffer-window (current-buffer) 0)))
- (if win (set-window-point win (point))))
+ (let ((point (point)))
+ (save-current-buffer
+ (funcall display-function (current-buffer)))
+ (let ((win (get-buffer-window (current-buffer) 0)))
+ (if win (set-window-point win point))))
;; FIXME: we used to only run bookmark-after-jump-hook in
;; `bookmark-jump' itself, but in none of the other commands.
(when bookmark-fringe-mark
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#71603
; Package
emacs
.
(Mon, 17 Jun 2024 11:59:02 GMT)
Full text and
rfc822 format available.
Message #11 received at 71603 <at> debbugs.gnu.org (full text, mbox):
> Cc: 71603 <at> debbugs.gnu.org
> Date: Mon, 17 Jun 2024 08:34:29 +0200
> From: Eshel Yaron via "Bug reports for GNU Emacs,
> the Swiss army knife of text editors" <bug-gnu-emacs <at> gnu.org>
>
> > The expected behavior: jump cursor to bk1 or bk2
> >
> > The actual behavior: nothing happens, except the left fringe displays an additional bookmark icon if your current
> > point is not at one of the bookmark locations.
>
> Thanks, I can reproduce this issue on master. Does the diff below yield
> the expected behavior?
Thanks, I have independently came to the same solution. So please
install this on master, but with a comment explaining why we record
point before calling display-function.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#71603
; Package
emacs
.
(Mon, 17 Jun 2024 15:16:01 GMT)
Full text and
rfc822 format available.
Message #14 received at 71603 <at> debbugs.gnu.org (full text, mbox):
Eli Zaretskii <eliz <at> gnu.org> writes:
>> Cc: 71603 <at> debbugs.gnu.org
>> Date: Mon, 17 Jun 2024 08:34:29 +0200
>> From: Eshel Yaron via "Bug reports for GNU Emacs,
>> the Swiss army knife of text editors" <bug-gnu-emacs <at> gnu.org>
>>
>> > The expected behavior: jump cursor to bk1 or bk2
>> >
>> > The actual behavior: nothing happens, except the left fringe displays an additional bookmark icon if your current
>> > point is not at one of the bookmark locations.
>>
>> Thanks, I can reproduce this issue on master. Does the diff below yield
>> the expected behavior?
>
> Thanks, I have independently came to the same solution. So please
> install this on master, but with a comment explaining why we record
> point before calling display-function.
All right, see commit 27f46ba4b96.
Eshel
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#71603
; Package
emacs
.
(Mon, 17 Jun 2024 18:36:02 GMT)
Full text and
rfc822 format available.
Message #17 received at 71603 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
> Does the diff below yield
the expected behavior?
Yes. It works perfectly.
Thanks.
Best regards,
Siyuan Chen
On Mon, Jun 17, 2024 at 11:15 PM Eshel Yaron <me <at> eshelyaron.com> wrote:
> Eli Zaretskii <eliz <at> gnu.org> writes:
>
> >> Cc: 71603 <at> debbugs.gnu.org
> >> Date: Mon, 17 Jun 2024 08:34:29 +0200
> >> From: Eshel Yaron via "Bug reports for GNU Emacs,
> >> the Swiss army knife of text editors" <bug-gnu-emacs <at> gnu.org>
> >>
> >> > The expected behavior: jump cursor to bk1 or bk2
> >> >
> >> > The actual behavior: nothing happens, except the left fringe displays
> an additional bookmark icon if your current
> >> > point is not at one of the bookmark locations.
> >>
> >> Thanks, I can reproduce this issue on master. Does the diff below yield
> >> the expected behavior?
> >
> > Thanks, I have independently came to the same solution. So please
> > install this on master, but with a comment explaining why we record
> > point before calling display-function.
>
> All right, see commit 27f46ba4b96.
>
>
> Eshel
>
[Message part 2 (text/html, inline)]
Reply sent
to
Eli Zaretskii <eliz <at> gnu.org>
:
You have taken responsibility.
(Sat, 22 Jun 2024 08:56:02 GMT)
Full text and
rfc822 format available.
Notification sent
to
Siyuan Chen <chansey97 <at> gmail.com>
:
bug acknowledged by developer.
(Sat, 22 Jun 2024 08:56:02 GMT)
Full text and
rfc822 format available.
Message #22 received at 71603-done <at> debbugs.gnu.org (full text, mbox):
> From: Eshel Yaron <me <at> eshelyaron.com>
> Cc: chansey97 <at> gmail.com, 71603 <at> debbugs.gnu.org
> Date: Mon, 17 Jun 2024 17:15:18 +0200
>
> Eli Zaretskii <eliz <at> gnu.org> writes:
>
> >> Cc: 71603 <at> debbugs.gnu.org
> >> Date: Mon, 17 Jun 2024 08:34:29 +0200
> >> From: Eshel Yaron via "Bug reports for GNU Emacs,
> >> the Swiss army knife of text editors" <bug-gnu-emacs <at> gnu.org>
> >>
> >> > The expected behavior: jump cursor to bk1 or bk2
> >> >
> >> > The actual behavior: nothing happens, except the left fringe displays an additional bookmark icon if your current
> >> > point is not at one of the bookmark locations.
> >>
> >> Thanks, I can reproduce this issue on master. Does the diff below yield
> >> the expected behavior?
> >
> > Thanks, I have independently came to the same solution. So please
> > install this on master, but with a comment explaining why we record
> > point before calling display-function.
>
> All right, see commit 27f46ba4b96.
Thanks, closing.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Sat, 20 Jul 2024 11:24:04 GMT)
Full text and
rfc822 format available.
This bug report was last modified 1 year and 30 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.