summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJSDurand <mmemmew@gmail.com>2022-01-04 22:24:12 +0800
committerJSDurand <mmemmew@gmail.com>2022-01-04 22:24:12 +0800
commit1495b4a5530c6435b598d76b2f9e89ebeeb093a2 (patch)
tree5d37b2d1021d075d99c69b8d1a3cec47c5fad630
parent8e52f0c296db9b70621d59ec1a5cb0a31c1af6a4 (diff)
C-n/p should also scroll to the completion list as well
* completion-conf.el (minibuffer-local-completion-map) (completion-list-mode-map): Bind C-n and C-p to move the cursor to the completion list buffer if the cursor is already at the bottom or the top of the minibuffer.
-rw-r--r--completion-conf.el4
1 files changed, 4 insertions, 0 deletions
diff --git a/completion-conf.el b/completion-conf.el
index 1ed310a..47d59ad 100644
--- a/completion-conf.el
+++ b/completion-conf.el
@@ -45,11 +45,15 @@
(define-key minibuffer-local-completion-map (vector 'down) #'durand-embark-scroll-down-or-go-to-completions)
(define-key minibuffer-local-completion-map (vector 'up) #'durand-embark-scroll-up-or-go-to-completions)
+(define-key minibuffer-local-completion-map (vector ?\C-n) #'durand-embark-scroll-down-or-go-to-completions)
+(define-key minibuffer-local-completion-map (vector ?\C-p) #'durand-embark-scroll-up-or-go-to-completions)
(define-key minibuffer-local-completion-map (vector ?\s-v) #'durand-completion-toggle-display)
(define-key minibuffer-local-completion-map (vector 32) nil)
(define-key minibuffer-local-must-match-map (vector 32) nil)
(define-key completion-list-mode-map (vector 'down) #'durand-completion-scroll-down-or-go-to-minibuffer)
(define-key completion-list-mode-map (vector 'up) #'durand-completion-scroll-up-or-go-to-minibuffer)
+(define-key completion-list-mode-map (vector ?\C-n) #'durand-completion-scroll-down-or-go-to-minibuffer)
+(define-key completion-list-mode-map (vector ?\C-p) #'durand-completion-scroll-up-or-go-to-minibuffer)
;;;###autoload
(defvar durand-headlong-entered-minibuffer-p nil