module-hydra.el (3837B)
1 ;; (use-package hydra 2 ;; :ensure t 3 ;; :bind (("C-c h" . hydra-apropos/body) 4 ;; ("M-p" . hydra-window/body) 5 ;; ("C-x SPC" . hydra-rectangle/body)) 6 ;; :config 7 ;; (progn (defhydra hydra-goto-line (goto-map "" 8 ;; :pre (linum-mode 1) 9 ;; :post (linum-mode -1)) 10 ;; "goto-line" 11 ;; ("g" goto-line "go") 12 ;; ("m" set-mark-command "mark" :bind nil) 13 ;; ("q" nil "quit")) 14 15 ;; (defhydra hydra-apropos (:color blue) 16 ;; "Apropos" 17 ;; ("m" man "man") 18 ;; ("a" apropos "apropos") 19 ;; ("c" apropos-command "cmd") 20 ;; ("d" apropos-documentation "doc") 21 ;; ("e" apropos-value "val") 22 ;; ("l" apropos-library "lib") 23 ;; ("o" apropos-user-option "option") 24 ;; ("u" apropos-user-option "option") 25 ;; ("v" apropos-variable "var") 26 ;; ("i" info-apropos "info") 27 ;; ("t" tags-apropos "tags") 28 ;; ("z" hydra-customize-apropos/body "customize")) 29 30 ;; (defhydra hydra-customize-apropos (:color blue) 31 ;; "Apropos (customize)" 32 ;; ("a" customize-apropos "apropos") 33 ;; ("f" customize-apropos-faces "faces") 34 ;; ("g" customize-apropos-groups "groups") 35 ;; ("o" customimze-apropos-options "options")) 36 37 ;; (defhydra hydra-rectangle (:body-pre (rectangle-mark-mode 1) 38 ;; :color pink 39 ;; :hint nil 40 ;; :post (deactivate-mark)) 41 ;; " 42 ;; ^_k_^ _w_ copy _o_pen _N_umber-lines |\\ -,,,--,,_ 43 ;; _h_ _l_ _y_ank _t_ype _e_xchange-point /,`.-'`' .. \-;;,_ 44 ;; ^_j_^ _d_ kill _c_lear _r_eset-region-mark |,4- ) )_ .;.( `'-' 45 ;; ^^^^ _u_ndo _g_ quit ^ ^ '---''(./..)-'(_\_) 46 ;; " 47 ;; ("k" rectangle-previous-line) 48 ;; ("j" rectangle-next-line) 49 ;; ("h" rectangle-backward-char) 50 ;; ("l" rectangle-forward-char) 51 ;; ("d" kill-rectangle) ;; C-x r k 52 ;; ("y" yank-rectangle) ;; C-x r y 53 ;; ("w" copy-rectangle-as-kill) ;; C-x r M-w 54 ;; ("o" open-rectangle) ;; C-x r o 55 ;; ("t" string-rectangle) ;; C-x r t 56 ;; ("c" clear-rectangle) ;; C-x r c 57 ;; ("e" rectangle-exchange-point-and-mark) ;; C-x C-x 58 ;; ("N" rectangle-number-lines) ;; C-x r N 59 ;; ("r" (if (region-active-p) 60 ;; (deactivate-mark) 61 ;; (rectangle-mark-mode 1))) 62 ;; ("u" undo nil) 63 ;; ("g" nil)) ;; ok 64 65 ;; (defhydra hydra-window (:color red 66 ;; :columns nil) 67 ;; ;; " 68 ;; ;; ^_k_^ _r_ horiz _a_ balance _s_ swap 69 ;; ;; _h_ _l_ _v_ vertical _t_ transpose _q_ others 70 ;; ;; ^_j_^ _w_ kill _u_ undo _g_ quit" 71 ;; ("h" windmove-left) 72 ;; ("j" windmove-down) 73 ;; ("k" windmove-up) 74 ;; ("l" windmove-right) 75 ;; ("r" split-window-right) 76 ;; ("v" split-window-below) 77 ;; ("t" toggle-window-split) 78 ;; ("q" delete-other-windows :exit t) 79 ;; ("w" delete-window) 80 ;; ("a" balance-windows) 81 ;; ("s" ace-swap-window) 82 ;; ("d" ace-delete-window) 83 ;; ("g" nil) 84 ;; ("u" (progn (winner-undo) (setq this-command 'winner-undo))))))