aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuangxiong Lin <[email protected]>2022-03-13 10:52:33 +0800
committerGuangxiong Lin <[email protected]>2022-03-13 10:52:33 +0800
commit7da4e7a4597ee1129c5bc7df40b4e4e586ff5edd (patch)
tree3ca76fc8272228a0ede3bee6a346f12ab4fb6d51
parent1ebe008da2a6c0eef703a39c72b12d1705ba9e0f (diff)
downloaddotfiles-7da4e7a4597ee1129c5bc7df40b4e4e586ff5edd.tar.gz
dotfiles-7da4e7a4597ee1129c5bc7df40b4e4e586ff5edd.tar.bz2
dotfiles-7da4e7a4597ee1129c5bc7df40b4e4e586ff5edd.zip
Update the config of im (emacs)
-rw-r--r--.emacs.d/lisp/init-input-method.el13
1 files changed, 5 insertions, 8 deletions
diff --git a/.emacs.d/lisp/init-input-method.el b/.emacs.d/lisp/init-input-method.el
index d9390b2..5c0c61b 100644
--- a/.emacs.d/lisp/init-input-method.el
+++ b/.emacs.d/lisp/init-input-method.el
@@ -6,17 +6,14 @@
(when *is-a-mac*
(setq sis-external-ism "/usr/local/bin/macism")
(setq sis-english-source "com.apple.keylayout.ABC"
- sis-other-source "com.apple.inputmethod.SCIM.ITABC")
- (setq sis-do-set
- (lambda (source) (start-process "set-input-source" nil
- sis-external-ism source)))
- (setq sis-do-get
- (lambda () (start-process "get-input-source" nil
- sis-external-ism)))
+ sis-other-source "com.apple.inputmethod.SCIM.ITABC")
(when (gx/maybe-require-package 'sis)
(add-hook 'after-init-hook
(lambda ()
(sis-global-respect-mode t)
- (sis-global-context-mode t)))))
+ (sis-global-context-mode t))))
+
+ (with-eval-after-load 'sis
+ (add-hook 'evil-insert-state-exit-hook 'sis-set-english)))
(provide 'init-input-method)