major-mode-hydra.el
major-mode-hydra.el copied to clipboard
Hide menu?
Firstly, thank you for the LOVELY package. Coming from vim, hydra combined with major / pretty mode hydra is a lovely alternative to the Evil impedance mismatch.
What I am wondering is if there is a way to bind a key to hide the menu while still keeping the hydra active? This seems to exist in the regular hydra (https://github.com/abo-abo/hydra/issues/301#issuecomment-460652087) but I am wondering how I'd recreate something like that with the pretty hydra?
Thanks!
Hi sorry for the super super late response. I know it has been a very long time. I haven't been actively working on emacs stuff due to work and family and I finally got some time again. I didn't know about this feature and it seems pretty cool! Keen to implement it into major/pretty hydra macros.
I'm thinking of an extra keyword parameter :show-hide-key
which when provided adds a key that toggles the visibility of the menu.
(pretty-hydra-define jp-window (:foreign-keys warn :title jp-window--title :quit-key "q" :show-hide-key "?")
("Actions"
(("TAB" other-window "switch")
("x" ace-delete-window "delete")
("m" ace-delete-other-windows "maximize")
("s" ace-swap-window "swap")
("a" ace-select-window "select"))
"Resize"
(("h" move-border-left "←")
("j" move-border-down "↓")
("k" move-border-up "↑")
("l" move-border-right "→")
("n" balance-windows "balance")
("f" toggle-frame-fullscreen "toggle fullscreen"))
"Split"
(("b" split-window-right "horizontally")
("B" split-window-horizontally-instead "horizontally instead")
("v" split-window-below "vertically")
("V" split-window-vertically-instead "vertically instead"))
"Zoom"
(("+" zoom-in "in")
("=" zoom-in)
("-" zoom-out "out")
("0" jp-zoom-default "reset"))))