Variable: query-replace-map
query-replace-map is a variable defined in replace.el.gz.
Value
Large value
! automatic
, act-and-show
. act-and-exit
<backspace> skip
<delete> skip
<escape> exit-prefix
<f1> help
<help> help
<next> scroll-up
<prior> scroll-down
<return> exit
? help
C-M-S-v scroll-other-window-down
C-M-v scroll-other-window
C-] quit
C-g quit
C-h help
C-l recenter
C-r edit
C-v scroll-up
C-w delete-and-edit
DEL skip
E edit-replacement
M-<next> scroll-other-window
M-<prior> scroll-other-window-down
M-v scroll-down
N skip
RET exit
SPC act
U undo-all
Y act
^ backup
e edit-replacement
n skip
q exit
u undo
y act
Documentation
Keymap of responses to questions posed by commands like query-replace.
The "bindings" in this map are not commands; they are answers.
The valid answers include act, skip, act-and-show,
act-and-exit, exit, exit-prefix, recenter, scroll-up,
scroll-down, scroll-other-window, scroll-other-window-down,
edit, edit-replacement, delete-and-edit, automatic,
backup, undo, undo-all, quit, and help.
This keymap is used by y-or-n-p as well as query-replace.
Probably introduced at or before Emacs version 26.1.
Source Code
;; Defined in /usr/src/emacs/lisp/replace.el.gz
(defvar query-replace-map
(let ((map (make-sparse-keymap)))
(define-key map " " 'act)
(define-key map "\d" 'skip)
(define-key map [delete] 'skip)
(define-key map [backspace] 'skip)
(define-key map "y" 'act)
(define-key map "n" 'skip)
(define-key map "Y" 'act)
(define-key map "N" 'skip)
(define-key map "e" 'edit-replacement)
(define-key map "E" 'edit-replacement)
(define-key map "," 'act-and-show)
(define-key map "q" 'exit)
(define-key map "\r" 'exit)
(define-key map [return] 'exit)
(define-key map "." 'act-and-exit)
(define-key map "\C-r" 'edit)
(define-key map "\C-w" 'delete-and-edit)
(define-key map "\C-l" 'recenter)
(define-key map "!" 'automatic)
(define-key map "^" 'backup)
(define-key map "u" 'undo)
(define-key map "U" 'undo-all)
(define-key map "\C-h" 'help)
(define-key map [f1] 'help)
(define-key map [help] 'help)
(define-key map "?" 'help)
(define-key map "\C-g" 'quit)
(define-key map "\C-]" 'quit)
(define-key map "\C-v" 'scroll-up)
(define-key map "\M-v" 'scroll-down)
(define-key map [next] 'scroll-up)
(define-key map [prior] 'scroll-down)
(define-key map [?\C-\M-v] 'scroll-other-window)
(define-key map [M-next] 'scroll-other-window)
(define-key map [?\C-\M-\S-v] 'scroll-other-window-down)
(define-key map [M-prior] 'scroll-other-window-down)
;; Binding ESC would prohibit the M-v binding. Instead, callers
;; should check for ESC specially.
;; (define-key map "\e" 'exit-prefix)
(define-key map [escape] 'exit-prefix)
map)
"Keymap of responses to questions posed by commands like `query-replace'.
The \"bindings\" in this map are not commands; they are answers.
The valid answers include `act', `skip', `act-and-show',
`act-and-exit', `exit', `exit-prefix', `recenter', `scroll-up',
`scroll-down', `scroll-other-window', `scroll-other-window-down',
`edit', `edit-replacement', `delete-and-edit', `automatic',
`backup', `undo', `undo-all', `quit', and `help'.
This keymap is used by `y-or-n-p' as well as `query-replace'.")