GNU bug report logs -
#35353
26.2; Buffer *xref*: (1) hard-coded mouse-1, (2) major mode name
Previous Next
Reported by: Drew Adams <drew.adams <at> oracle.com>
Date: Sun, 21 Apr 2019 03:07:02 UTC
Severity: minor
Found in version 26.2
Done: Lars Ingebrigtsen <larsi <at> gnus.org>
Bug is archived. No further changes may be made.
Full log
Message #77 received at 35353 <at> debbugs.gnu.org (full text, mbox):
On 22.04.2019 16:08, Drew Adams wrote:
> I
> see only `C-o' (`xref-show-location-at-point'),
> whose name says it does that, but only for point,
> not for the mouse position. (And when I try `C-o'
> it too switches to another window, the same as `RET'.)
It doesn't do that over here.
> In any case, how is Xref different from, say, Occur
> wrt mouse actions and the general interaction? What
> makes it so special that it should be problematic to
> fix this bug?
Honestly, it's quite easy. I'm pasting the code patch below.
Would you write the NEWS entry for it? And any necessary manual changes
would be nice as well.
diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el
index c7f015b94f..6dcdd75c84 100644
--- a/lisp/progmodes/xref.el
+++ b/lisp/progmodes/xref.el
@@ -722,8 +722,9 @@ xref--next-error-function
(defvar xref--button-map
(let ((map (make-sparse-keymap)))
(define-key map [(control ?m)] #'xref-goto-xref)
- (define-key map [mouse-1] #'xref-goto-xref)
- (define-key map [mouse-2] #'xref--mouse-2)
+ (define-key map [follow-link] 'mouse-face)
+ (define-key map [mouse-2] #'xref-goto-xref)
+ (define-key map [mouse-3] #'xref--mouse-3)
map))
(defun xref--mouse-2 (event)
This bug report was last modified 3 years and 18 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.