From ebe8a0daf5a9e6d37994956d651382e5709f9242 Mon Sep 17 00:00:00 2001 From: Kenichi Handa Date: Sun, 19 Jul 1998 05:17:35 +0000 Subject: [PATCH] (quail-japanese-update-translation): Handle a key which should fix the current translation and start a new translation correctly. (quail-japanese-toggle-kana): Set quail-translating to nil. Don't change point. --- leim/quail/japanese.el | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/leim/quail/japanese.el b/leim/quail/japanese.el index b2e0a459d08..42df5372d37 100644 --- a/leim/quail/japanese.el +++ b/leim/quail/japanese.el @@ -36,7 +36,10 @@ ((null control-flag) (if (/= (aref quail-current-key 0) ?q) (insert (or quail-current-str quail-current-key)))) - (t ; i.e. (numberp control-flag) + ((= control-flag 0) + (insert (aref quail-current-key 0)) + (quail-terminate-translation)) + (t (cond ((= (aref quail-current-key 0) ?n) (insert ?ん)) ((= (aref quail-current-key 0) (aref quail-current-key 1)) @@ -54,6 +57,7 @@ ;; Convert Hiragana <-> Katakana in the current translation region. (defun quail-japanese-toggle-kana () (interactive) + (setq quail-translating nil) (let ((start (overlay-start quail-conv-overlay)) (end (overlay-end quail-conv-overlay))) (setq quail-japanese-kana-state @@ -61,8 +65,7 @@ (not quail-japanese-kana-state))) (if quail-japanese-kana-state (japanese-hiragana-region start end) - (japanese-katakana-region start end)) - (goto-char (overlay-end quail-conv-overlay)))) + (japanese-katakana-region start end)))) ;; Convert Hiragana in the current translation region to Kanji by KKC ;; (Kana Kanji Converter) utility. -- 2.39.2