Function: kkc-next-phrase
kkc-next-phrase is an interactive and byte-compiled function defined
in kkc.el.gz.
Signature
(kkc-next-phrase)
Documentation
Fix the currently converted string and try to convert the remaining string.
Key Bindings
Source Code
;; Defined in /usr/src/emacs/lisp/international/kkc.el.gz
(defun kkc-next-phrase ()
"Fix the currently converted string and try to convert the remaining string."
(interactive)
(if (>= kkc-length-head (length kkc-current-key))
(kkc-terminate)
(setq kkc-length-head (- (length kkc-current-key) kkc-length-head))
(goto-char (overlay-end kkc-overlay-head))
(while (and (< (point) (overlay-end kkc-overlay-tail))
(looking-at "\\CH"))
(goto-char (match-end 0))
(setq kkc-length-head (1- kkc-length-head)))
(if (= kkc-length-head 0)
(kkc-terminate)
(let ((newkey (make-vector kkc-length-head 0))
(idx (- (length kkc-current-key) kkc-length-head))
(len kkc-length-head)
(i 0))
;; For the moment, (setq kkc-original-kana (concat newkey))
;; doesn't work.
(setq kkc-original-kana "")
(while (< i kkc-length-head)
(aset newkey i (aref kkc-current-key (+ idx i)))
(setq kkc-original-kana
(concat kkc-original-kana (char-to-string (aref newkey i))))
(setq i (1+ i)))
(setq kkc-current-key newkey)
(setq kkc-length-converted 0)
(while (and (not (kkc-lookup-key kkc-length-head nil
(< kkc-length-head len)))
(> kkc-length-head 1))
(setq kkc-length-head (1- kkc-length-head)))
(let ((pos (point))
(tail (overlay-end kkc-overlay-tail)))
(move-overlay kkc-overlay-head pos tail)
(move-overlay kkc-overlay-tail tail tail))
(kkc-update-conversion 'all)))))