@item mouse-2
The same as @code{mouse-1}, but make the window displaying the
@file{*xref*} buffer the selected window
-(@code{xref-select-and-goto-xref}).
+(@code{xref-select-and-show-xref}).
@item n
@itemx .
(defvar xref--button-map
(let ((map (make-sparse-keymap)))
(define-key map [mouse-1] #'xref-goto-xref)
- (define-key map [mouse-2] #'xref-select-and-goto-xref)
+ (define-key map [mouse-2] #'xref-select-and-show-xref)
map))
-(defun xref-select-and-goto-xref (event)
+(defun xref-select-and-show-xref (event)
"Move point to the button and show the xref definition.
The window showing the xref buffer will be selected."
(interactive "e")
(or (get-text-property (point) 'xref-item)
(xref--search-property 'xref-item))
(xref-show-location-at-point))
+
(define-obsolete-function-alias
- 'xref--mouse-2 #'xref-select-and-goto-xref "28.1")
+ 'xref--mouse-2 #'xref-select-and-show-xref "28.1")
(defcustom xref-truncation-width 400
"The column to visually \"truncate\" each Xref buffer line to."