Revise debug/help keybindings & commands
This commit is contained in:
parent
d6220201d7
commit
254298b1b0
3 changed files with 18 additions and 17 deletions
|
@ -18,16 +18,16 @@
|
||||||
(propertize "Faces:" 'face 'font-lock-comment-face)
|
(propertize "Faces:" 'face 'font-lock-comment-face)
|
||||||
(if faces (string-join faces ", ") "n/a"))))
|
(if faces (string-join faces ", ") "n/a"))))
|
||||||
|
|
||||||
;;;###autoload
|
(defun doom-active-minor-modes ()
|
||||||
(defun doom/what-col ()
|
"Get a list of active minor-mode symbols."
|
||||||
(interactive)
|
(cl-remove-if (lambda (m) (and (boundp m) (symbol-value m)))
|
||||||
(message "Column %d" (current-column)))
|
minor-mode-list))
|
||||||
|
|
||||||
;;;###autoload
|
;;;###autoload
|
||||||
(defun doom/what-bindings (key)
|
(defun doom/what-minor-mode (mode)
|
||||||
(interactive "k")
|
"Get information on an active minor mode. Use `describe-minor-mode' for a
|
||||||
(message "minor-mode:\t%s\nlocal:\t\t%s\nglobal:\t\t%s"
|
selection of all minor-modes, active or not."
|
||||||
(or (minor-mode-key-binding key) "n/a")
|
(interactive
|
||||||
(or (local-key-binding key) "n/a")
|
(list (completing-read "Minor mode: "
|
||||||
(or (global-key-binding key) "n/a")))
|
(doom-active-minor-modes))))
|
||||||
|
(describe-minor-mode-from-symbol (intern mode)))
|
||||||
|
|
|
@ -314,10 +314,13 @@
|
||||||
:n "o" #'ace-link-help)
|
:n "o" #'ace-link-help)
|
||||||
|
|
||||||
(:map help-map
|
(:map help-map
|
||||||
"l" #'find-library
|
:desc "Describe face" "h" #'describe-face ; overwrites `view-hello-file'
|
||||||
"L" #'view-lossage
|
:desc "Face at point" "H" #'doom/what-face
|
||||||
"h" #'describe-face ; more useful than `view-hello-file'
|
:desc "Minor-mode" "M" #'doom/what-minor-mode
|
||||||
"g" #'describe-char)) ; more useful than `describe-gnu-project'
|
:desc "Command log" "W" #'global-command-log-mode
|
||||||
|
:desc "Find library" "l" #'find-library
|
||||||
|
:desc "View lossage" "L" #'view-lossage
|
||||||
|
:desc "Describe char" "g" #'describe-char)) ; overwrites `describe-gnu-project'
|
||||||
|
|
||||||
|
|
||||||
;;
|
;;
|
||||||
|
|
|
@ -7,8 +7,6 @@
|
||||||
;;; Custom commands
|
;;; Custom commands
|
||||||
;; Emacs utilities
|
;; Emacs utilities
|
||||||
(ex! "bc[omp]" #'+hlissner:byte-compile)
|
(ex! "bc[omp]" #'+hlissner:byte-compile)
|
||||||
(ex! "clog" #'global-command-log-mode)
|
|
||||||
(ex! "minor" #'describe-minor-mode) ; list minor modes
|
|
||||||
(ex! "re[load]" #'doom/reload)
|
(ex! "re[load]" #'doom/reload)
|
||||||
(ex! "re[load]au" #'doom/reload-autoloads)
|
(ex! "re[load]au" #'doom/reload-autoloads)
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue