Function: projectile-replace--render-preserve
projectile-replace--render-preserve is a byte-compiled function
defined in projectile.el.
Signature
(projectile-replace--render-preserve)
Documentation
Redraw the results buffer, keeping point on the same line.
Restoring by line rather than by position is what makes this safe while a scan is streaming: matches are appended and a file header keeps its line count when its tally grows, so the lines already on screen do not move.
Source Code
;; Defined in ~/.emacs.d/elpa/projectile-20260820.1509/projectile.el
(defun projectile-replace--render-preserve ()
"Redraw the results buffer, keeping point on the same line.
Restoring by line rather than by position is what makes this safe while a
scan is streaming: matches are appended and a file header keeps its line
count when its tally grows, so the lines already on screen do not move."
(let ((line (line-number-at-pos)))
(funcall projectile-replace--render-function)
(goto-char (point-min))
(forward-line (1- line))))