1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-02-04 06:31:13 -08:00

Add a doc string to xref-current-item

* lisp/progmodes/xref.el (xref-after-jump-hook): Link to it.
(xref-current-item): Add a doc string to the now-public variable.
This commit is contained in:
Lars Ingebrigtsen 2022-04-17 12:17:30 +02:00
parent d951e9e650
commit 4d60d9face
2 changed files with 12 additions and 5 deletions

View file

@ -942,12 +942,16 @@ to enable the display of the buffer list.
It is bound to 'C-M-,' and jumps to the location where 'xref-go-back'
('M-,', also known as 'xref-pop-marker-stack') was invoked previously.
*** 'xref-query-replace-in-results' does not prompt for FROM when
called without prefix argument, to make the most common case faster:
replacing entire matches.
+++
*** 'xref-query-replace-in-results' prompting change.
This command no longer prompts for FROM when called without prefix
argument. This makes the most common case faster: replacing entire
matches.
+++
*** New command 'xref-find-references-and-replace' to rename one identifier.
---
*** New variable 'xref-current-item' (renamed from a private version).
*** New function 'xref-show-xrefs'.

View file

@ -381,7 +381,8 @@ elements is negated: these commands will NOT prompt."
(defcustom xref-after-jump-hook '(recenter
xref-pulse-momentarily)
"Functions called after jumping to an xref."
"Functions called after jumping to an xref.
Also see `xref-current-item'."
:type 'hook)
(defcustom xref-after-return-hook '(xref-pulse-momentarily)
@ -490,7 +491,9 @@ To undo, use \\[xref-go-forward]."
'xref-current-item
"29.1")
(defvar xref-current-item nil)
(defvar xref-current-item nil
"Dynamically bound to the current item being processed.
This can be used from `xref-after-jump-hook', for instance.")
(defun xref-pulse-momentarily ()
(pcase-let ((`(,beg . ,end)