diff options
author | Kyle Meyer <kyle@kyleam.com> | 2017-04-10 23:30:58 -0400 |
---|---|---|
committer | Kyle Meyer <kyle@kyleam.com> | 2017-04-10 23:30:58 -0400 |
commit | ef72f72055a21c81587ddf0d17ab5a0dccdef9b2 (patch) | |
tree | f6680cacf45bb5fc09f25d4b3084c82dfaea1219 | |
parent | bdd35ad4df4f4dc5f1a30c6556781c97bb4a0ecb (diff) | |
download | emacs.d-ef72f72055a21c81587ddf0d17ab5a0dccdef9b2.tar.gz |
lispy: Toggle off/on with view-mode on/off
-rw-r--r-- | init.el | 8 |
1 files changed, 7 insertions, 1 deletions
@@ -1880,7 +1880,13 @@ ;; `imenu-create-index-function' from being set to ;; `semantic-create-imenu-index'. Trying to set it in ;; `emacs-lisp-mode-hook' or `lispy-mode-hook' doesn't work. - (defalias 'semantic-create-imenu-index 'imenu-default-create-index-function)) + (defalias 'semantic-create-imenu-index 'imenu-default-create-index-function) + + (after 'view + (add-hook 'view-mode-hook + (lambda () + (when (derived-mode-p 'emacs-lisp-mode 'scheme-mode) + (funcall #'lispy-mode (if view-mode -1 1))))))) (use-package geiser :config |