mirror of
https://github.com/doomemacs/doomemacs.git
synced 2025-12-06 02:30:33 -08:00
Merge 969f46091f into 9ef731939a
This commit is contained in:
commit
4d7146f0bd
1 changed files with 19 additions and 4 deletions
|
|
@ -263,8 +263,23 @@ orderless."
|
|||
(use-package! embark
|
||||
:defer t
|
||||
:init
|
||||
(setq which-key-use-C-h-commands nil
|
||||
;; Allow C-h to open Consult when calling which-key without a prefix.
|
||||
(setq which-key-use-C-h-commands t
|
||||
prefix-help-command #'embark-prefix-help-command)
|
||||
(defvar +vertico-which-key-current-keymap nil
|
||||
"The current keymap being displayed by which-key.")
|
||||
(defadvice! +vertico-which-key-update-current-keymap-a (_keymap-name keymap &rest args)
|
||||
:before #'which-key--show-keymap
|
||||
(setq +vertico-which-key-current-keymap keymap))
|
||||
(defadvice! +vertico-which-key-consult-C-h-dispatch (oldfun)
|
||||
:around #'which-key-C-h-dispatch
|
||||
(setq this-command 'embark-prefix-help-command)
|
||||
(cond ((not (which-key--popup-showing-p))
|
||||
(call-interactively #'embark-prefix-help-command))
|
||||
((string-empty-p (which-key--current-key-string))
|
||||
(embark-bindings-in-keymap +vertico-which-key-current-keymap))
|
||||
(t (call-interactively #'embark-prefix-help-command))))
|
||||
|
||||
(map! [remap describe-bindings] #'embark-bindings
|
||||
"C-;" #'embark-act ; to be moved to :config default if accepted
|
||||
(:map minibuffer-local-map
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue