-*** [[https://github.com/Kungsgeten/ryo-modal][ryo-modal]]
-
-#+begin_quote
-Roll your own modal mode
-#+end_quote
-
-#+begin_src emacs-lisp
-(use-package ryo-modal
- :commands ryo-modal-mode
- :bind ("M-m" . ryo-modal-mode)
- :after which-key
- :config
- (push '((nil . "ryo:.*:") . (nil . "")) which-key-replacement-alist)
- (ryo-modal-keys
- ("," ryo-modal-repeat)
- ("b" backward-char)
- ("n" next-line)
- ("p" previous-line)
- ("f" forward-char)
- ("/" undo)
- ("i" ryo-modal-mode)
- ("l" recenter-top-bottom)
- ("v" scroll-up-command)
- ("V" scroll-down-command)
- ("x" delete-forward-char)
- ("SPC" (("b" (("b" ibuffer-list-buffers)
- ("k" kill-this-buffer)
- ("o" other-window)
- ("s" save-buffer)))
- ("B" (("A" borg-activate)
- ("a" borg-assimilate)
- ("b" borg-build)
- ("c" borg-clone)
- ("r" borg-remove)))
- ("h" (("c" describe-char)
- ("f" describe-function)
- ("F" describe-face)
- ("i" info)
- ("k" describe-key)
- ("l" view-lossage)
- ("v" describe-variable)))
- ("q" (("q" save-buffers-kill-terminal)))))
- ("d" (("w" kill-word)
- ("b" backward-kill-word)))
- ("c w" kill-word :exit t))
-
- (ryo-modal-keys
- ;; First argyment to ryo-modal-keys may be a list of keywords.
- ;; These keywords will be applied to all keybindings.
- (:norepeat t)
- ("0" "M-0")
- ("1" "M-1")
- ("2" "M-2")
- ("3" "M-3")
- ("4" "M-4")
- ("5" "M-5")
- ("6" "M-6")
- ("7" "M-7")
- ("8" "M-8")
- ("9" "M-9"))
- :hook ((text-mode . ryo-modal-mode)
- (prog-mode . ryo-modal-mode)))
-#+end_src
-