Last active
October 16, 2015 07:44
-
-
Save kikairoya/587b83c2aabb586c91f6 to your computer and use it in GitHub Desktop.
ddskkの挙動が気に食わなかった
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(when (require 'skk nil t) | |
(global-set-key (kbd "C-x j") 'skk-auto-fill-mode) | |
(global-set-key (kbd "C-x C-j") 'skk-auto-fill-mode) | |
(setq default-input-method "japanese-skk") | |
(setq skk-egg-like-newline t) | |
(defun u-skk-ctrlj-force-hiragana () | |
(interactive) | |
(if (and (boundp 'isearch-mode) | |
isearch-mode) | |
nil | |
(skk-j-mode-on))) | |
(defun u-skk-ctrlj-hack () | |
(when (current-local-map) | |
(let ((k (lookup-key (current-local-map) "\C-j"))) | |
(when k | |
(local-set-key (kbd "M-C-j") k)))) | |
(define-key skk-j-mode-map "\C-j" 'u-skk-ctrlj-force-hiragana)) | |
(defun u-skk-isearch-begin () | |
(when (and (boundp 'skk-mode) | |
skk-mode | |
skk-isearch-mode-enable) | |
(skk-isearch-mode-setup))) | |
(defun u-skk-isearch-end () | |
(when (and (featurep 'skk-isearch) | |
skk-isearch-mode-enable) | |
(skk-isearch-mode-cleanup))) | |
(add-hook 'isearch-mode-hook 'u-skk-isearch-begin) | |
(add-hook 'isearch-mode-end-hook 'u-skk-isearch-end) | |
(add-hook 'skk-mode-hook 'u-skk-ctrlj-hack) | |
(require 'skk-hint) | |
(require 'skk-study)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment