From e1777c01106c8875ce51f7078f285ba8cc38d352 Mon Sep 17 00:00:00 2001 From: tomo Date: Sun, 30 Aug 1998 09:51:50 +0000 Subject: [PATCH] This commit was manufactured by cvs2svn to create tag 'egg-980304'. --- egg-edep.el | 44 ----- egg/canna.el | 287 -------------------------------- egg/cannarpc.el | 201 ----------------------- euc-china.el | 484 ------------------------------------------------------ euc-cn.el | 449 -------------------------------------------------- its/ascii.el | 55 ------- its/erpin.el | 387 ------------------------------------------- its/hankata.el | 291 --------------------------------- its/jeonkak.el | 103 ------------ its/kata.el | 489 ------------------------------------------------------- its/quanjiao.el | 169 ------------------- its/zenkaku.el | 103 ------------ its/zhuyin.el | 288 -------------------------------- 13 files changed, 3350 deletions(-) delete mode 100644 egg-edep.el delete mode 100644 egg/canna.el delete mode 100644 egg/cannarpc.el delete mode 100644 euc-china.el delete mode 100644 euc-cn.el delete mode 100644 its/ascii.el delete mode 100644 its/erpin.el delete mode 100644 its/hankata.el delete mode 100644 its/jeonkak.el delete mode 100644 its/kata.el delete mode 100644 its/quanjiao.el delete mode 100644 its/zenkaku.el delete mode 100644 its/zhuyin.el diff --git a/egg-edep.el b/egg-edep.el deleted file mode 100644 index 2d1e3d9..0000000 --- a/egg-edep.el +++ /dev/null @@ -1,44 +0,0 @@ -;; This file serves Emacs version dependent definitions - -(if (and (fboundp 'set-buffer-multibyte) - (subrp (symbol-function 'set-buffer-multibyte))) - ;; Emacs 20.3 - (progn - (defun egg-char-bytes (x) 1) - (defun egg-charset-bytes (x) 1) - (defun egg-char-bytes-at (str pos) 1) - (defun egg-chars-in-period (str pos len) len) - (defalias 'egg-string-to-vector 'identity) - (defalias 'egg-string-to-char-at 'aref) - ) - ;; Emacs 20.2 - (defun set-buffer-multibyte (flag) - (setq enable-multibyte-characters flag)) - (defalias 'string-as-unibyte 'identity) - (defalias 'string-as-multibyte 'identity) - (defalias 'coding-system-put 'put) - - (defalias 'egg-char-bytes 'char-bytes) - (defalias 'egg-charset-bytes 'charset-bytes) - (defun egg-char-bytes-at (str pos) - (char-bytes (egg-string-to-char-at str pos))) - (defun egg-chars-in-period (str pos len) - (chars-in-string (substring str pos (+ pos len)))) - (defalias 'egg-string-to-vector 'string-to-vector) - (defun egg-string-to-char-at (str pos) - (let ((c (aref str pos))) - (if (or (< c ?\200) - (>= c ?\240) - (>= (1+ pos) (length str)) - (< (aref str (1+ pos)) ?\240)) - c - (string-match "[\240-\377]+" str (1+ pos)) - (string-to-char (substring str pos (match-end 0)))))) - ) - -;; Elisp bug fix - -(defun egg-next-single-property-change (pos prop &optional object limit) - (min limit (next-single-property-change pos prop object (1+ limit)))) - -(provide 'egg-edep) diff --git a/egg/canna.el b/egg/canna.el deleted file mode 100644 index c401aa2..0000000 --- a/egg/canna.el +++ /dev/null @@ -1,287 +0,0 @@ -;;; egg/canna.el --- Canna Support (high level interface) in -;;; Egg Input Method Architecture - -;; Copyright (C) 1998 Mule Project, -;; Powered by Electrotechnical Laboratory, JAPAN. -;; Project Leader: Satoru Tomura - -;; Author: NIIBE Yutaka -;; Maintainer: NIIBE Yutaka - -;; This file is part of EGG. - -;; EGG is free software; you can redistribute it and/or modify -;; it under the terms of the GNU General Public License as published by -;; the Free Software Foundation; either version 2, or (at your option) -;; any later version. - -;; EGG is distributed in the hope that it will be useful, -;; but WITHOUT ANY WARRANTY; without even the implied warranty of -;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -;; GNU General Public License for more details. - -;; You should have received a copy of the GNU General Public License -;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. - -;;; Commentary: - -;;; Code: - -(require 'egg-edep) - -(defconst canna-support-languages '(Japanese)) - -(eval-when-compile - (defmacro CANNA-const (c) - (cond ((eq c 'FileNotExist) xxxxxxxxxxxxxx) - ))) - -(defconst canna-conversion-backend - [ canna-init - - canna-start-conversion - canna-get-bunsetsu-converted - canna-get-bunsetsu-source - canna-list-candidates - canna-get-number-of-candidates - canna-get-current-candidate-number - canna-get-all-candidates - canna-decide-candidate - canna-change-bunsetsu-length - canna-end-conversion - nil - - canna-fini - ]) - -(defconst canna-server-port 5680 "Port number of Canna server") -(defvar canna-hostname "localhost" - "Hostname of Canna server") - -(defun canna-open (hostname) - "Establish the connection to CANNA server. Return environment object." - (let* ((buf (generate-new-buffer " *CANNA*")) - (proc (open-network-stream "CANNA" buf hostname canna-server-port)) - result) - (process-kill-without-query proc) - (set-process-coding-system proc 'no-conversion 'no-conversion) - (set-marker-insertion-type (process-mark proc) t) - (save-excursion - (set-buffer buf) - (erase-buffer) - (buffer-disable-undo) - (set-buffer-multibyte nil)) - (setq result (cannarpc-open proc (user-login-name))) - (if (< result 0) - (let ((msg (cannarpc-get-error-message (- result)))) - (delete-process proc) - (kill-buffer buf) - (error "Can't open CANNA session (%s): %s" hostname msg))) - (vector proc result))) - -;; XXX: Should support multiple outstanding context -;; ::= [ ] -(defvar canna-environment nil - "Environment for CANNA kana-kanji conversion") - -(defsubst cannaenv-get-proc (env) - (aref env 0)) -(defsubst cannaenv-get-context (env) - (aref env 1)) - -;; ::= -;; [ -;; ] -(defsubst canna-make-bunsetsu (env converted bunsetsu-pos) - (vector env converted bunsetsu-pos nil nil nil)) - -(defsubst cannabunsetsu-get-env (b) - (aref b 0)) -(defsubst cannabunsetsu-get-converted (b) - (aref b 1)) -(defsubst cannabunsetsu-get-bunsetsu-pos (b) - (aref b 2)) -(defsubst cannabunsetsu-get-source (b) - (aref b 3)) -(defsubst cannabunsetsu-set-source (b s) - (aset b 3 s)) -(defsubst cannabunsetsu-get-zenkouho-pos (b) - (aref b 4)) -(defsubst cannabunsetsu-set-zenkouho-pos (b p) - (aset b 4 p)) -(defsubst cannabunsetsu-get-zenkouho (b) - (aref b 5)) -(defsubst cannabunsetsu-set-zenkouho (b z) - (aset b 5 z)) - -(defun canna-get-bunsetsu-source (b) - (let ((s (cannabunsetsu-get-source b))) - (or s - (let* ((env (cannabunsetsu-get-env b)) - (bp (cannabunsetsu-get-bunsetsu-pos b)) - (s (cannarpc-get-bunsetsu-source env bp))) - (cannabunsetsu-set-source b s))))) - -(defun canna-get-bunsetsu-converted (b) - (cannabunsetsu-get-converted b)) - -(defconst canna-dictionary-specification - '("iroha" - "fuzokugo" - "hojomwd" - "hojoswd" - "bushu" - ("user") - ) - "Dictionary specification of CANNA.") - -(defun canna-filename (p) - "" - (cond ((consp p) (concat (car p) "/" (user-login-name))) - (t p))) - -(defun canna-get-environment () - "Return the backend of CANNA environment." - (if canna-environment - canna-environment - (let* ((env (canna-open canna-hostname)) - (l canna-dictionary-specification) - dict-list) - (while l - (let ((dic (car l)) - result) - (setq result - (canna-open-dictionary env (canna-filename dic))) - (if (= result 255) - (error "Damedamedame") ; XXX - (setq l (cdr l))))) - (setq canna-environment env)))) - -(defun canna-open-dictionary (env name) - (let ((trying t) - ret) - (while trying - (setq ret (cannarpc-open-dictionary env name 0)) ; XXX MODE=0 - (if (= ret 0) - (setq trying nil) - (message "$B<-=q%U%!%$%k(B(%s)$B$,$"$j$^$;$s(B" name) - (setq ret (- ret)) ; Get error code. - (if (and (y-or-n-p - (format "$B<-=q%U%!%$%k(B(%s)$B$,$"$j$^$;$s!#:n$j$^$9$+(B? " - name)) - (= (cannarpc-make-dictionary env name) 0)) - (message "$B<-=q%U%!%$%k(B(%s)$B$r:n$j$^$7$?(B" name) - (error "Fatal")))) - ret)) - -(defun canna-init () - ) - -(defun canna-start-conversion (yomi lang) - "Convert YOMI string to kanji, and enter conversion mode. -Return the list of bunsetsu." - (let ((env (canna-get-environment))) - (cannarpc-begin-conversion env yomi))) - -(defun canna-end-conversion (bunsetsu-list abort) - (let* ((env (cannabunsetsu-get-env (car bunsetsu-list))) - (l bunsetsu-list) - (len (length bunsetsu-list)) - (zenkouho-pos-vector (make-vector (* 2 len) 0)) - (i 0) - (mode 1) ;XXX MODE=1 attru? - bunsetsu zenkouho-pos) - (if abort - (setq mode 0)) - (while l - (setq bunsetsu (car l)) - (setq l (cdr l)) - (setq zenkouho-pos (cannabunsetsu-get-zenkouho-pos bunsetsu)) - (if (null zenkouho-pos) - () ; XXX: NIL--> 0 atteru??? - (aset zenkouho-pos-vector i 0) ; XXX Don't support >=256 - (aset zenkouho-pos-vector (1+ i) zenkouho-pos)) - (setq i (+ i 2))) - (cannarpc-end-conversion env len zenkouho-pos-vector 0))) - -(defun canna-list-candidates (bunsetsu prev-bunsetsu) - (let* ((env (cannabunsetsu-get-env bunsetsu)) - (bunsetsu-pos (cannabunsetsu-get-bunsetsu-pos bunsetsu)) - (z (cannarpc-get-bunsetsu-candidates env bunsetsu-pos))) - (cannabunsetsu-set-zenkouho bunsetsu z) - (cannabunsetsu-set-zenkouho-pos bunsetsu 0) - 0)) - -(defun canna-get-number-of-candidates (bunsetsu) - (let ((l (cannabunsetsu-get-zenkouho bunsetsu))) - (if l - (length l) - nil))) - -(defun canna-decide-candidate (bunsetsu candidate-pos) - (let* ((candidate-list (cannabunsetsu-get-zenkouho bunsetsu)) - (candidate (nth candidate-pos candidate-list))) - (cannabunsetsu-set-zenkouho candidate candidate-list) - (cannabunsetsu-set-zenkouho-pos candidate candidate-pos) - candidate)) - -(defun canna-get-current-candidate-number (bunsetsu) - (cannabunsetsu-get-zenkouho-pos bunsetsu)) - -(defun canna-get-all-candidates (bunsetsu) - (let* ((l (cannabunsetsu-get-zenkouho bunsetsu)) - (result (cons nil nil)) - (r result)) - (catch 'break - (while t - (let ((candidate (car l))) - (setcar r (cannabunsetsu-get-converted candidate)) - (if (null (setq l (cdr l))) - (throw 'break nil) - (setq r (setcdr r (cons nil nil))))))) - result)) - -;;;;;;;;;;;;;;;;;;;;;;; MADAMADA zenzendame, just copy from SJ3 -(defun canna-change-bunsetsu-length (b0 b1 b2 len) - (let ((yomi (concat - (cannabunsetsu-get-source b1) - (if b2 (cannabunsetsu-get-source b2)))) - (env (cannabunsetsu-get-env b1)) - yomi1 yomi2 - bunsetsu1 bunsetsu2) - (setq yomi1 (substring yomi 0 len) - yomi2 (substring yomi len)) - (setq bunsetsu1 - (cannarpc-tanbunsetsu-conversion env yomi1)) - ;; Only set once (memory original length of the bunsetsu). - (cannabunsetsu-set-kugiri-changed bunsetsu1 - (or (cannabunsetsu-get-kugiri-changed b1) - (length (cannabunsetsu-get-source b1)))) - (if (< 0 (length yomi2)) - (setq bunsetsu2 (cannarpc-tanbunsetsu-conversion env yomi2)) - (setq bunsetsu2 nil)) - (if bunsetsu2 - (list bunsetsu1 bunsetsu2) - (list bunsetsu1)))) - -;;;;;;;;;;;;;; MADAMADA -(defun canna-fini (lang) -) - -;;; setup - -(require 'egg) -(load "egg/cannarpc") - -;;;###autoload -(defun egg-activate-canna (&rest arg) - "Activate CANNA backend of Tamagotchy." - (egg-set-support-languages canna-support-languages) - (egg-set-conversion-backend canna-conversion-backend - canna-support-languages - nil) - (apply 'egg-mode arg)) - -;;; egg/canna.el ends here. diff --git a/egg/cannarpc.el b/egg/cannarpc.el deleted file mode 100644 index fadaf05..0000000 --- a/egg/cannarpc.el +++ /dev/null @@ -1,201 +0,0 @@ -;;; egg/cannarpc.el --- Canna Support (low level interface) in -;;; Egg Input Method Architecture - -;; Copyright (C) 1997, 1998 Mule Project, -;; Powered by Electrotechnical Laboratory, JAPAN. -;; Project Leader: Satoru Tomura - -;; Author: NIIBE Yutaka -;; Maintainer: NIIBE Yutaka - -;; This file is part of EGG. - -;; EGG is free software; you can redistribute it and/or modify -;; it under the terms of the GNU General Public License as published by -;; the Free Software Foundation; either version 2, or (at your option) -;; any later version. - -;; EGG is distributed in the hope that it will be useful, -;; but WITHOUT ANY WARRANTY; without even the implied warranty of -;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -;; GNU General Public License for more details. - -;; You should have received a copy of the GNU General Public License -;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. - -;;; Commentary: - -;;; Code: - -(eval-when-compile - (require 'egg-com) -;; (load-library "egg/canna") - (defmacro canna-const (c) - (cond ((eq c 'Initialize) 1) - ((eq c 'Finalize) 2) - ((eq c 'CreateContext) 3) - ((eq c 'CloseContext) 5) - ((eq c 'GetDictionaryList) 6) - ((eq c 'GetDirectoryList) 7) - ((eq c 'MountDictionary) 8) - ((eq c 'UnmountDictionary) 9) - ((eq c 'BeginConvert) 15) - ((eq c 'EndConvert) 16) - ((eq c 'GetCandidacyList) 17) - ((eq c 'GetYomi) 18) - ((eq c 'ResizePause) 26) - - ((eq c 'CreateDictionary) 3) - (t (error "No such constant"))))) - -(defun cannarpc-get-error-message (errno) - (or (aref cannarpc-error-message errno) (format "#%d" errno))) - -(defmacro cannarpc-call-with-environment (e vlist send-expr &rest receive-exprs) - (let ((v (append - `((proc (cannaenv-get-proc ,e)) - (context (cannaenv-get-context ,e))) - vlist))) - (list - 'let v - (append - `(save-excursion - (set-buffer (process-buffer proc)) - (erase-buffer) - ,send-expr - (process-send-region proc (point-min) (point-max)) - (goto-char (prog1 (point) (accept-process-output proc)))) - receive-exprs)))) - -(defconst canna-version-fmt "2.0:%s") - -(defun cannarpc-open (proc username) - "Open the session. Return 0 on success, error code on failure." - (let ((verusr (format canna-version-fmt username))) - (comm-call-with-proc proc (result) - (comm-format (u u v) (canna-const Initialize) (length verusr) verusr) - (comm-unpack (u) result) - result))) - -(defun cannarpc-close (proc) - (comm-call-with-proc proc (dummy result) - (comm-format (b b w) (canna-const Finalize) 0 0) - (comm-unpack (b b w b) dummy dummy dummy result) - result)) - -(defun cannarpc-create-context (proc) - (comm-call-with-proc proc (dummy result) - (comm-format (b b w) (canna-const CreateContext) 0 0) - (comm-unpack (b b w w) dummy dummy dummy result) - result)) - -(defun cannarpc-close-context (proc context) - (comm-call-with-proc proc (dummy result) - (comm-format (b b w w) (canna-const CloseContext) 0 2 context) - (comm-unpack (b b w b) dummy dummy dummy result) - result)) - -;; XXX: Not implemented fully -(defun cannarpc-get-dictionary-list (env) - (cannarpc-call-with-environment env (dymmy result) - (comm-format (b b w w w) (canna-const GetDictionaryList) 0 4 - context 1024) - (comm-unpack (u w) dummy result) - ;; follow list of dictionaries - result)) - -;; XXX: Not implemented fully -(defun cannarpc-get-directory-list (env) - (cannarpc-call-with-environment env (dymmy result) - (comm-format (b b w w w) (canna-const GetDirectoryList) 0 4 - context 1024) - (comm-unpack (u w) dummy result) - ;; follow list of directories - result)) - -(defun cannarpc-open-dictionary (env dict-file-name mode) - (cannarpc-call-with-environment env (dymmy result) - (comm-format (b b w u w s) (canna-const MountDictionary) 0 - (+ (length dict-file-name) 7) - mode context dict-file-name) - (comm-unpack (u b) dummy result) - result)) - -(defun cannarpc-close-dictionary (env dict-file-name mode) - (cannarpc-call-with-environment env (dymmy result) - (comm-format (b b w u w s) (canna-const UnmountDictionary) 0 - (+ (length dict-file-name) 6) - mode context dict-file-name) - (comm-unpack (u b) dummy result) - result)) - -(defun cannarpc-begin-conversion (env yomi) - "Begin conversion." - (let ((yomi-ext (encode-coding-string yomi 'euc-japan)) - (i 0) - converted bunsetsu-list bl) - (cannarpc-call-with-environment env (dummy result) - (comm-format (b b w u w S) (canna-const BeginConvert) 0 - (+ (length yomi-ext) 8) 0 context yomi) - (comm-unpack (u w) dummy result) - (if (= result 65535) - -1 ; failure - (while (< i result) - (comm-unpack (S) converted) - (let ((bl1 (cons (canna-make-bunsetsu env converted i) - nil))) - (if bl - (setq bl (setcdr bl bl1)) - (setq bunsetsu-list (setq bl bl1)))) - (setq i (1+ i))) - bunsetsu-list)))) - -(defun cannarpc-end-conversion (env len zenkouho-pos-vector mode) - "End conversion." - (cannarpc-call-with-environment env (dummy result) - (comm-format (b b w w w u v) (canna-const EndConvert) 0 - (+ (* len 2) 8) context len mode zenkouho-pos-vector) - (comm-unpack (u b) dummy result) - (if (= result 255) - -1 ; failure - result))) - -(defun cannarpc-make-dictionary (env dict-name) - (cannarpc-call-with-environment env (dummy result) - (comm-format (b b w u w s) (canna-const CreateDictionary) 1 - (+ (length dict-name) 7) 0 context dict-name) - (comm-unpack (u b) dummy result) - result)) - -(defun cannarpc-get-bunsetsu-source (env bunsetsu-pos) - (cannarpc-call-with-environment env (dummy result) - (comm-format (b b w w w w) (canna-const GetYomi) 0 6 context - bunsetsu-pos 1024) - (comm-unpack (u w) dummy result) - (if (= result 65535) - -1 - (comm-unpack (S) result) - result))) - -(defun cannarpc-get-bunsetsu-candidates (env bunsetsu-pos) - (let ((i 0) - converted bunsetsu-list bl) - (cannarpc-call-with-environment env (dummy result) - (comm-format (b b w w w w) (canna-const GetCandidacyList) 0 6 context - bunsetsu-pos 1024) - (comm-unpack (u w) dymmy result) - (if (= result 65535) - -1 ; failure - (while (< i result) - (comm-unpack (S) converted) - (let ((bl1 (cons (canna-make-bunsetsu env converted bunsetsu-pos) - nil))) - (if bl - (setq bl (setcdr bl bl1)) - (setq bunsetsu-list (setq bl bl1)))) - (setq i (1+ i))) - bunsetsu-list)))) - -;;; egg/cannarpc.el ends here. diff --git a/euc-china.el b/euc-china.el deleted file mode 100644 index ebcfb00..0000000 --- a/euc-china.el +++ /dev/null @@ -1,484 +0,0 @@ -;;; euc-china.el --- Fixed EUC-CN/TW handling routines. - -;; Copyright (C) 1997, 1998 Mule Project, -;; Powered by Electrotechnical Laboratory, JAPAN. -;; Project Leader: Satoru Tomura - -;; Author: KATAYAMA Yoshio -;; Maintainer: KATAYAMA Yoshio -;; Keywords: mule, multilingual, input method, chinese - -;; This file will be part of GNU Emacs (in future). - -;; EGG is free software; you can redistribute it and/or modify -;; it under the terms of the GNU General Public License as published by -;; the Free Software Foundation; either version 2, or (at your option) -;; any later version. - -;; EGG is distributed in the hope that it will be useful, -;; but WITHOUT ANY WARRANTY; without even the implied warranty of -;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -;; GNU General Public License for more details. - -;; You should have received a copy of the GNU General Public License -;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. - -;;; Commentary: - - -;;; Code: - -(defvar egg-zhuyin nil) - -(defconst yincode-pinyin-shengmu - '(("" . 0) ("B" . 1) ("C" . 2) ("Ch" . 3) ("D" . 4) - ("F" . 5) ("G" . 6) ("H" . 7) ("J" . 8) ("K" . 9) - ("L" . 10) ("M" . 11) ("N" . 12) ("P" . 13) ("Q" . 14) - ("R" . 15) ("S" . 16) ("Sh" . 17) ("T" . 18) ("W" . 19) - ("X" . 20) ("Y" . 21) ("Z" . 22) ("Zh" . 23))) - -(defconst yincode-pinyin-yunmu - '(("(0@(B" 0 0) ("(0@(B" 0 1) ("(0@(B" 0 3) ("(0@(B" 0 5) ("(0@(B" 0 7) - ("a(0@(B" 1 0) ("(0!@(B" 1 1) ("(0"@(B" 1 3) ("(0#@(B" 1 5) ("(0$@(B" 1 7) - ("ai(0@(B" 2 0) ("(0!(Bi(0@(B" 2 1) ("(0"(Bi(0@(B" 2 3) ("(0#(Bi(0@(B" 2 5) ("(0$(Bi(0@(B" 2 7) - ("an(0@(B" 3 0) ("(0!(Bn(0@(B" 3 1) ("(0"(Bn(0@(B" 3 3) ("(0#(Bn(0@(B" 3 5) ("(0$(Bn(0@(B" 3 7) - ("ang(0@(B" 4 0) ("(0!(Bng(0@(B" 4 1) ("(0"(Bng(0@(B" 4 3) ("(0#(Bng(0@(B" 4 5) ("(0$(Bng(0@(B" 4 7) - ("ao(0@(B" 5 0) ("(0!(Bo(0@(B" 5 1) ("(0"(Bo(0@(B" 5 3) ("(0#(Bo(0@(B" 5 5) ("(0$(Bo(0@(B" 5 7) - ("e(0@(B" 6 0) ("(0%@(B" 6 1) ("(0&@(B" 6 3) ("(0'@(B" 6 5) ("(0(@(B" 6 7) - ("ei(0@(B" 7 0) ("(0%(Bi(0@(B" 7 1) ("(0&(Bi(0@(B" 7 3) ("(0'(Bi(0@(B" 7 5) ("(0((Bi(0@(B" 7 7) - ("en(0@(B" 8 0) ("(0%(Bn(0@(B" 8 1) ("(0&(Bn(0@(B" 8 3) ("(0'(Bn(0@(B" 8 5) ("(0((Bn(0@(B" 8 7) - ("eng(0@(B" 9 0) ("(0%(Bng(0@(B" 9 1) ("(0&(Bng(0@(B" 9 3) ("(0'(Bng(0@(B" 9 5) ("(0((Bng(0@(B" 9 7) - ("er(0@(B" 10 0) ("(0%(Br(0@(B" 10 1) ("(0&(Br(0@(B" 10 3) ("(0'(Br(0@(B" 10 5) ("(0((Br(0@(B" 10 7) - ("i(0@(B" 11 0) ("(0)@(B" 11 1) ("(0*@(B" 11 3) ("(0+@(B" 11 5) ("(0,@(B" 11 7) - ("ia(0@(B" 12 0) ("i(0!@(B" 12 1) ("i(0"@(B" 12 3) ("i(0#@(B" 12 5) ("i(0$@(B" 12 7) - ("ian(0@(B" 13 0) ("i(0!(Bn(0@(B" 13 1) ("i(0"(Bn(0@(B" 13 3) ("i(0#(Bn(0@(B" 13 5) ("i(0$(Bn(0@(B" 13 7) - ("iang(0@(B" 14 0) ("i(0!(Bng(0@(B" 14 1) ("i(0"(Bng(0@(B" 14 3) ("i(0#(Bng(0@(B" 14 5) ("i(0$(Bng(0@(B" 14 7) - ("iao(0@(B" 15 0) ("i(0!(Bo(0@(B" 15 1) ("i(0"(Bo(0@(B" 15 3) ("i(0#(Bo(0@(B" 15 5) ("i(0$(Bo(0@(B" 15 7) - ("ie(0@(B" 16 0) ("i(0%@(B" 16 1) ("i(0&@(B" 16 3) ("i(0'@(B" 16 5) ("i(0(@(B" 16 7) - ("in(0@(B" 17 0) ("(0)(Bn(0@(B" 17 1) ("(0*(Bn(0@(B" 17 3) ("(0+(Bn(0@(B" 17 5) ("(0,(Bn(0@(B" 17 7) - ("ing(0@(B" 18 0) ("(0)(Bng(0@(B" 18 1) ("(0*(Bng(0@(B" 18 3) ("(0+(Bng(0@(B" 18 5) ("(0,(Bng(0@(B" 18 7) - ("iong(0@(B" 19 0) ("i(0-(Bng(0@(B" 19 1) ("i(0.(Bng(0@(B" 19 3) ("i(0/(Bng(0@(B" 19 5) ("i(00(Bng(0@(B" 19 7) - ("iu(0@(B" 20 0) ("i(01@(B" 20 1) ("i(02@(B" 20 3) ("i(03@(B" 20 5) ("i(04@(B" 20 7) - ("m(0@(B" 21 0) ("m(0@(B" 21 1) ("m(0@(B" 21 3) ("m(0@(B" 21 5) ("m(0@(B" 21 7) - ("n(0@(B" 22 0) ("n(0@(B" 22 1) ("(0=@(B" 22 3) ("(0>@(B" 22 5) ("(0?@(B" 22 7) - ("ng(0@(B" 23 0) ("ng(0@(B" 23 1) ("ng(0@(B" 23 3) ("ng(0@(B" 23 5) ("ng(0@(B" 23 7) - ("o(0@(B" 24 0) ("(0-@(B" 24 1) ("(0.@(B" 24 3) ("(0/@(B" 24 5) ("(00@(B" 24 7) - ("ong(0@(B" 25 0) ("(0-(Bng(0@(B" 25 1) ("(0.(Bng(0@(B" 25 3) ("(0/(Bng(0@(B" 25 5) ("(00(Bng(0@(B" 25 7) - ("ou(0@(B" 26 0) ("(0-(Bu(0@(B" 26 1) ("(0.(Bu(0@(B" 26 3) ("(0/(Bu(0@(B" 26 5) ("(00(Bu(0@(B" 26 7) - ("u(0@(B" 27 0) ("(01@(B" 27 1) ("(02@(B" 27 3) ("(03@(B" 27 5) ("(04@(B" 27 7) - ("ua(0@(B" 28 0) ("u(0!@(B" 28 1) ("u(0"@(B" 28 3) ("u(0#@(B" 28 5) ("u(0$@(B" 28 7) - ("uai(0@(B" 29 0) ("u(0!(Bi(0@(B" 29 1) ("u(0"(Bi(0@(B" 29 3) ("u(0#(Bi(0@(B" 29 5) ("u(0$(Bi(0@(B" 29 7) - ("uan(0@(B" 30 0) ("u(0!(Bn(0@(B" 30 1) ("u(0"(Bn(0@(B" 30 3) ("u(0#(Bn(0@(B" 30 5) ("u(0$(Bn(0@(B" 30 7) - ("uang(0@(B" 31 0) ("u(0!(Bng(0@(B" 31 1) ("u(0"(Bng(0@(B" 31 3) ("u(0#(Bng(0@(B" 31 5) ("u(0$(Bng(0@(B" 31 7) - ("ue(0@(B" 32 0) ("u(0%@(B" 32 1) ("u(0&@(B" 32 3) ("u(0'@(B" 32 5) ("u(0(@(B" 32 7) - ("ui(0@(B" 33 0) ("u(0)@(B" 33 1) ("u(0*@(B" 33 3) ("u(0+@(B" 33 5) ("u(0,@(B" 33 7) - ("un(0@(B" 34 0) ("(01(Bn(0@(B" 34 1) ("(02(Bn(0@(B" 34 3) ("(03(Bn(0@(B" 34 5) ("(04(Bn(0@(B" 34 7) - ("uo(0@(B" 35 0) ("u(0-@(B" 35 1) ("u(0.@(B" 35 3) ("u(0/@(B" 35 5) ("u(00@(B" 35 7) - ("(09@(B" 36 0) ("(05@(B" 36 1) ("(06@(B" 36 3) ("(07@(B" 36 5) ("(08@(B" 36 7) - ("(09(Be(0@(B" 37 0) ("(09%@(B" 37 1) ("(09&@(B" 37 3) ("(09'@(B" 37 5) ("(09(@(B" 37 7) - ("0(0@(B" 38 0) ("1(0@(B" 38 1) ("2(0@(B" 38 3) ("3(0@(B" 38 5) ("4(0@(B" 38 7))) - -(defconst yincode-pinyin-table - [ - 0 1 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 1 1 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 - 0 1 1 1 1 1 0 1 1 1 0 1 0 1 0 1 1 1 1 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0 0 0 0 1 - 0 1 1 1 1 1 1 1 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 0 0 1 0 0 1 1 1 0 0 1 - 0 1 1 1 1 1 1 0 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 0 1 1 1 0 0 1 - 0 1 1 1 1 1 1 1 1 1 0 1 1 1 0 1 1 0 1 0 1 0 0 0 0 1 1 1 0 0 1 0 0 1 1 1 0 0 1 - 0 1 0 1 1 0 0 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 1 1 0 0 0 0 0 0 0 0 0 0 1 - 0 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 0 1 1 1 0 0 1 - 0 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 1 0 1 0 1 1 1 1 1 1 1 0 1 1 1 0 0 1 - 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 1 0 0 1 0 1 0 1 0 0 0 1 - 0 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 0 1 1 1 0 0 1 - 0 1 1 1 1 1 1 1 0 1 0 1 1 1 1 1 1 1 1 0 1 0 0 0 1 1 1 1 0 0 1 0 0 0 1 1 1 1 1 - 0 1 1 1 1 1 1 1 1 1 0 1 0 1 0 1 1 1 1 0 1 0 0 0 1 0 1 1 0 0 0 0 0 0 0 0 0 0 1 - 0 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 1 1 1 0 1 0 0 0 0 1 1 1 0 0 1 0 0 0 0 1 1 1 1 - 0 1 1 1 1 1 0 1 1 1 0 1 0 1 0 1 1 1 1 0 0 0 0 0 1 0 1 1 0 0 0 0 0 0 0 0 0 0 1 - 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 1 0 0 1 0 1 0 1 0 0 0 1 - 0 0 0 1 1 1 1 0 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 0 1 0 0 1 1 1 0 0 1 - 0 1 1 1 1 1 1 0 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 0 0 1 0 0 1 1 1 0 0 1 - 0 1 1 1 1 1 1 1 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 0 1 1 1 0 0 1 - 0 1 1 1 1 1 1 1 0 1 0 1 0 1 0 1 1 0 1 0 0 0 0 0 0 1 1 1 0 0 1 0 0 1 1 1 0 0 1 - 0 1 1 1 1 0 0 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0 0 0 0 1 - 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 1 0 0 1 0 1 0 1 0 0 0 1 - 0 1 0 1 1 1 1 0 0 0 0 1 0 0 0 0 0 1 1 0 0 0 0 0 1 1 1 1 0 0 1 0 1 0 1 0 0 0 1 - 0 1 1 1 1 1 1 1 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 0 0 1 0 0 1 1 1 0 0 1 - 0 1 1 1 1 1 1 1 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 0 1 1 1 0 0 1 - ]) - -(defconst yincode-zhuyin-shengmu - '(("" . 0) ("(0E(B" . 1) ("(0X(B" . 2) ("(0T(B" . 3) ("(0I(B" . 4) - ("(0H(B" . 5) ("(0M(B" . 6) ("(0O(B" . 7) ("(0P(B" . 8) ("(0N(B" . 9) - ("(0L(B" . 10) ("(0G(B" . 11) ("(0K(B" . 12) ("(0F(B" . 13) ("(0Q(B" . 14) - ("(0V(B" . 15) ("(0Y(B" . 16) ("(0U(B" . 17) ("(0J(B" . 18) ("(0h(B" . 19) - ("(0R(B" . 20) ("(0g(B" . 21) ("(0W(B" . 22) ("(0S(B" . 23))) - -(defconst yincode-zhuyin-yunmu - '(("(0@(B" 0 0) ("(0A(B" 0 1) ("(0B(B" 0 3) ("(0C(B" 0 5) ("(0D(B" 0 7) ; i - ("(0Z@(B" 1 0) ("(0ZA(B" 1 1) ("(0ZB(B" 1 3) ("(0ZC(B" 1 5) ("(0ZD(B" 1 7) ; a - ("(0^@(B" 2 0) ("(0^A(B" 2 1) ("(0^B(B" 2 3) ("(0^C(B" 2 5) ("(0^D(B" 2 7) ; ai - ("(0b@(B" 3 0) ("(0bA(B" 3 1) ("(0bB(B" 3 3) ("(0bC(B" 3 5) ("(0bD(B" 3 7) ; an - ("(0d@(B" 4 0) ("(0dA(B" 4 1) ("(0dB(B" 4 3) ("(0dC(B" 4 5) ("(0dD(B" 4 7) ; ang - ("(0`@(B" 5 0) ("(0`A(B" 5 1) ("(0`B(B" 5 3) ("(0`C(B" 5 5) ("(0`D(B" 5 7) ; ao - ("(0\@(B" 6 0) ("(0\A(B" 6 1) ("(0\B(B" 6 3) ("(0\C(B" 6 5) ("(0\D(B" 6 7) ; e - ("(0_@(B" 7 0) ("(0_A(B" 7 1) ("(0_B(B" 7 3) ("(0_C(B" 7 5) ("(0_D(B" 7 7) ; ei - ("(0c@(B" 8 0) ("(0cA(B" 8 1) ("(0cB(B" 8 3) ("(0cC(B" 8 5) ("(0cD(B" 8 7) ; en - ("(0e@(B" 9 0) ("(0eA(B" 9 1) ("(0eB(B" 9 3) ("(0eC(B" 9 5) ("(0eD(B" 9 7) ; eng - ("(0f@(B" 10 0) ("(0fA(B" 10 1) ("(0fB(B" 10 3) ("(0fC(B" 10 5) ("(0fD(B" 10 7) ; er - ("(0g@(B" 11 0) ("(0gA(B" 11 1) ("(0gB(B" 11 3) ("(0gC(B" 11 5) ("(0gD(B" 11 7) ; i - ("(0gZ@(B" 12 0) ("(0gZA(B" 12 1) ("(0gZB(B" 12 3) ("(0gZC(B" 12 5) ("(0gZD(B" 12 7) ; ia - ("(0gb@(B" 13 0) ("(0gbA(B" 13 1) ("(0gbB(B" 13 3) ("(0gbC(B" 13 5) ("(0gbD(B" 13 7) ; ian - ("(0gd@(B" 14 0) ("(0gdA(B" 14 1) ("(0gdB(B" 14 3) ("(0gdC(B" 14 5) ("(0gdD(B" 14 7) ; iang - ("(0g`@(B" 15 0) ("(0g`A(B" 15 1) ("(0g`B(B" 15 3) ("(0g`C(B" 15 5) ("(0g`D(B" 15 7) ; iao - ("(0g]@(B" 16 0) ("(0g]A(B" 16 1) ("(0g]B(B" 16 3) ("(0g]C(B" 16 5) ("(0g]D(B" 16 7) ; ie - ("(0gc@(B" 17 0) ("(0gcA(B" 17 1) ("(0gcB(B" 17 3) ("(0gcC(B" 17 5) ("(0gcD(B" 17 7) ; in - ("(0ge@(B" 18 0) ("(0geA(B" 18 1) ("(0geB(B" 18 3) ("(0geC(B" 18 5) ("(0geD(B" 18 7) ; ing - ("(0ie@(B" 19 0) ("(0ieA(B" 19 1) ("(0ieB(B" 19 3) ("(0ieC(B" 19 5) ("(0ieD(B" 19 7) ; iong - ("(0ga@(B" 20 0) ("(0gaA(B" 20 1) ("(0gaB(B" 20 3) ("(0gaC(B" 20 5) ("(0gaD(B" 20 7) ; iu - ("(0G@(B" 21 0) ("(0GA(B" 21 1) ("(0GB(B" 21 3) ("(0GC(B" 21 5) ("(0GD(B" 21 7) ; m - ("(0K@(B" 22 0) ("(0KA(B" 22 1) ("(0KB(B" 22 3) ("(0KC(B" 22 5) ("(0KD(B" 22 7) ; n - ("@(0@(B" 23 0) ("@(0A(B" 23 1) ("@(0B(B" 23 3) ("@(0C(B" 23 5) ("@(0D(B" 23 7) ; ng - ("(0[@(B" 24 0) ("(0[A(B" 24 1) ("(0[B(B" 24 3) ("(0[C(B" 24 5) ("(0[D(B" 24 7) ; o - ("(0he@(B" 25 0) ("(0heA(B" 25 1) ("(0heB(B" 25 3) ("(0heC(B" 25 5) ("(0heD(B" 25 7) ; ong - ("(0a@(B" 26 0) ("(0aA(B" 26 1) ("(0aB(B" 26 3) ("(0aC(B" 26 5) ("(0aD(B" 26 7) ; ou - ("(0h@(B" 27 0) ("(0hA(B" 27 1) ("(0hB(B" 27 3) ("(0hC(B" 27 5) ("(0hD(B" 27 7) ; u - ("(0hZ@(B" 28 0) ("(0hZA(B" 28 1) ("(0hZB(B" 28 3) ("(0hZC(B" 28 5) ("(0hZD(B" 28 7) ; ua - ("(0h^@(B" 29 0) ("(0h^A(B" 29 1) ("(0h^B(B" 29 3) ("(0h^C(B" 29 5) ("(0h^D(B" 29 7) ; uai - ("(0hb@(B" 30 0) ("(0hbA(B" 30 1) ("(0hbB(B" 30 3) ("(0hbC(B" 30 5) ("(0hbD(B" 30 7) ; uan - ("(0hd@(B" 31 0) ("(0hdA(B" 31 1) ("(0hdB(B" 31 3) ("(0hdC(B" 31 5) ("(0hdD(B" 31 7) ; uang - ("(0i]@(B" 37 0) ("(0i]A(B" 37 1) ("(0i]B(B" 37 3) ("(0i]C(B" 37 5) ("(0i]D(B" 37 7) ; ue - ("(0h_@(B" 33 0) ("(0h_A(B" 33 1) ("(0h_B(B" 33 3) ("(0h_C(B" 33 5) ("(0h_D(B" 33 7) ; ui - ("(0hc@(B" 34 0) ("(0hcA(B" 34 1) ("(0hcB(B" 34 3) ("(0hcC(B" 34 5) ("(0hcD(B" 34 7) ; un - ("(0h[@(B" 35 0) ("(0h[A(B" 35 1) ("(0h[B(B" 35 3) ("(0h[C(B" 35 5) ("(0h[D(B" 35 7) ; uo - ("(0i@(B" 36 0) ("(0iA(B" 36 1) ("(0iB(B" 36 3) ("(0iC(B" 36 5) ("(0iD(B" 36 7) ; (09(B - ("(0i]@(B" 37 0) ("(0i]A(B" 37 1) ("(0i]B(B" 37 3) ("(0i]C(B" 37 5) ("(0i]D(B" 37 7) ; (09(Be - ("0(0@(B" 38 0) ("1(0A(B" 38 1) ("2(0B(B" 38 3) ("3(0C(B" 38 5) ("4(0D(B" 38 7) ; undefined - ("(0ib@(B" 39 0) ("(0ibA(B" 39 1) ("(0ibB(B" 39 3) ("(0ibC(B" 39 5) ("(0ibD(B" 39 7) ; (09(Ban - ("(0ic@(B" 40 0) ("(0icA(B" 40 1) ("(0icB(B" 40 3) ("(0icC(B" 40 5) ("(0icD(B" 40 7) ; (09(Bn - )) - -(defconst yincode-zhuyin-table - [ - ;; empty ShengMu - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x9586 ?\x0000 ?\x9592 ?\x9599 - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x959b ?\x95a0 ?\x0000 ?\x959e - ?\x95a2 - ;; ShengMu B - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu C - ?\x828b ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x0280 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu Ch - ?\x838b ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 - ?\x0000 ?\x0380 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu D - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu F - ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu G - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu H - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu J - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x08a4 ?\x0000 ?\x0000 - ?\x08a7 ?\x0000 ?\x08a5 ?\x0000 ?\x08a8 ?\x0000 ?\x889b ?\x88a0 ?\x8000 ?\x889e - ?\x88a2 - ;; ShengMu K - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu L - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu M - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu N - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu P - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu Q - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0ea4 ?\x0000 ?\x0000 - ?\x0ea7 ?\x0000 ?\x0ea5 ?\x0000 ?\x0ea8 ?\x0000 ?\x8e9b ?\x8ea0 ?\x8000 ?\x8e9e - ?\x8ea2 - ;; ShengMu R - ?\x8f8b ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 - ?\x0000 ?\x0f80 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu S - ?\x908b ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 - ?\x0000 ?\x1080 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu Sh - ?\x918b ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x1180 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu T - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 - ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu W - ?\x939b ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 ?\x0000 ?\x1380 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu X - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x14a4 ?\x0000 ?\x0000 - ?\x14a7 ?\x0000 ?\x14a5 ?\x0000 ?\x14a8 ?\x0000 ?\x949b ?\x94a0 ?\x8000 ?\x949e - ?\x94a2 - ;; ShengMu Y - ?\x958b ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0090 ?\x0000 ?\x9591 ?\x9592 - ?\x0000 ?\x1580 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x1588 ?\x1589 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0093 ?\x8000 ?\x00a4 ?\x0000 ?\x0000 - ?\x00a7 ?\x0000 ?\x00a5 ?\x0000 ?\x00a8 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu Z - ?\x968b ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x1680 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu Zh - ?\x978b ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x1780 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ]) - -(defun egg-chinese-syllable (str &optional start) - (if start - (setq str (substring str start))) - (or (car (egg-pinyin-syllable str)) - (car (egg-zhuyin-syllable str)))) - -(defsubst egg-make-fixed-euc-china-code (s y) - (concat (list - (+ (* 2 (nth 1 y)) (logand (nth 2 y) 1) 32) - (+ (* 4 (if (= s 0) 20 s)) (lsh (nth 2 y) -1) 156)))) - -(defun egg-pinyin-syllable (str) - (let (s y end) - (if (string-match "^[A-Za-z(0!(B-(0?(B]+(0@(B" str) - (progn - (setq end (match-end 0)) - (cond - ((setq s (cdr (assoc (substring str 0 2) yincode-pinyin-shengmu))) - (setq y (substring str 2 end))) - ((setq s (cdr (assoc (substring str 0 1) yincode-pinyin-shengmu))) - (setq y (substring str 1 end))) - (t - (setq s 0 y (substring str 0 end)))) - (if (and (setq y (assoc y yincode-pinyin-yunmu)) - (= (aref yincode-pinyin-table (+ (* 39 s) (nth 1 y))) 1)) - (cons end (egg-make-fixed-euc-china-code s y))))))) - -(defun egg-zhuyin-syllable (str) - (let (end s y c z (zhuyin-len (charset-bytes 'chinese-sisheng))) - (if (string-match "^[(0E(B-(0i(B@0-4]+[(0@ABCD(B]" str) - (progn - (setq end (match-end 0) - c (substring str 0 zhuyin-len) - s (cdr (assoc c yincode-zhuyin-shengmu)) - y (assoc (substring str zhuyin-len end) yincode-zhuyin-yunmu)) - (if (null (and s y)) - (setq s 0 - y (assoc (substring str 0 end) yincode-zhuyin-yunmu))) - (if (and y - (setq z (aref yincode-zhuyin-table (+ (* 41 s) (nth 1 y)))) - (/= (logand z ?\x8000) 0)) - (if (/= (logand z ?\x80) 0) - (cons end (egg-make-fixed-euc-china-code - (logand (lsh z -8) ?\x7f) - (list nil (logand z ?\x7f) (nth 2 y)))) - (cons end (egg-make-fixed-euc-china-code s y)))))))) - -(defun encode-fixed-euc-china-region (beg end type) - "Encode the text in the region to EUC-CN/TW." - (let (s syl c cset (maxlen (max (length "Zhu(0!(Bng(0@(B") (length "(0ShdA(B")))) - (save-excursion - (save-restriction - (narrow-to-region beg end) - (goto-char (point-min)) - (while (< (point) (point-max)) - (setq s (buffer-substring (point) - (min (+ (point) maxlen) (point-max)))) - (cond - ((setq syl (egg-pinyin-syllable s)) - (delete-region (point) (+ (point) (car syl))) - (insert (cdr syl))) - ((setq syl (egg-zhuyin-syllable s)) - (delete-region (point) (+ (point) (car syl))) - (insert (cdr syl))) - (t - (setq c (split-char (following-char)) - cset (car c)) - (cond - ((or (and (eq cset 'chinese-gb2312) (eq type 'cn)) - (and (eq cset 'chinese-cns11643-1) (eq type 'tw))) - (delete-char 1) - (insert (+ (nth 1 c) 128) (+ (nth 2 c) 128))) - ((and (eq cset 'chinese-cns11643-2) (eq type 'tw)) - (delete-char 1) - (insert (+ (nth 1 c) 128) (nth 2 c))) - ((eq cset 'chinese-sisheng) - (delete-char 1) - (insert 0 (+ (nth 1 c) 128))) - (t - (delete-region (point) (1+ (point))) - (insert 0 (nth 1 c))))))) - (- (point-max) (point-min)))))) - -(defun pre-write-encode-fixed-euc-china (from to type) - (let ((buf (current-buffer)) - (work (get-buffer-create " *pre-write-encoding-work*"))) - (set-buffer work) - (erase-buffer) - (if (stringp from) - (insert from) - (insert-buffer-substring buf from to)) - (encode-fixed-euc-china-region 1 (point-max) type) - nil)) - -(defun pre-write-encode-euc-cn (from to) - (pre-write-encode-fixed-euc-china from to 'cn)) - -(defun pre-write-encode-euc-tw (from to) - (pre-write-encode-fixed-euc-china from to 'tw)) - -(defun decode-fixed-euc-china-region (beg end type) - "Decode EUC-CN/TW encoded text in the region. -Return the length of resulting text." - (interactive "r") - (prog1 - (let (c0 c1 s y ss) - (save-restriction - (narrow-to-region beg end) - (goto-char (point-min)) - (while (< (point) (point-max)) - (setq c1 (buffer-substring (point) (+ (point) 2)) - c0 (aref c1 0) - c1 (aref c1 1)) - (delete-region (point) (+ (point) 2)) - (cond - ((eq c0 0) - (if (> c1 ?\xa0) - (insert leading-code-private-11 - (charset-id 'chinese-sisheng) - c1) - (insert c1))) - ((>= c0 ?\x80) - (cond - ((eq type 'cn) - (insert (charset-id 'chinese-gb2312) c0 (logior c1 ?\x80))) - ((>= c0 ?\x80) - (insert (charset-id 'chinese-cns11643-1) c0 c1)) - (t - (insert (charset-id 'chinese-cns11643-2) c0 (+ c1 ?\x80))))) - (t - (setq c1 (logand c1 ?\x7f)) - (setq s (- (lsh c1 -2) 7) ;;(+ (lsh (- c1 32) -2) 1) - y (- (lsh c0 -1) 16) ;;(lsh (- c0 32) -1) - ss (+ (logand c0 1) (logand c1 3))) - (if egg-zhuyin - (progn - (setq c0 (aref yincode-zhuyin-table (+ (* 41 s) y))) - (if (eq (logand c0 ?\x8080) ?\x80) - (setq s (lsh c0 -8) - y (logand c0 ?\x7f))) - (if (and (eq s 20) - (eq (aref yincode-pinyin-table (+ (* 39 s) y)) 0)) - (setq s 0)) - (insert (car (nth s yincode-zhuyin-shengmu)) - (car (nth (+ (* 5 y) ss) yincode-zhuyin-yunmu)))) - (if (and (eq s 20) - (eq (aref yincode-pinyin-table (+ (* 39 s) y)) 0)) - (setq s 0)) - (insert (car (nth s yincode-pinyin-shengmu)) - (car (nth (+ (* 5 y) ss) yincode-pinyin-yunmu))))))) - (- (point-max) (point-min)))) - (if (looking-at "\0\0") (forward-char 2)))) - -(defun post-read-decode-fixed-euc-china (len type) - (let ((pos (point)) - (buffer-modified-p (buffer-modified-p))) - (prog1 - (decode-fixed-euc-china-region pos (+ pos len) type) - (set-buffer-modified-p buffer-modified-p)))) - -(defun post-read-decode-euc-cn (len) - (post-read-decode-fixed-euc-china len 'cn)) - -(defun post-read-decode-euc-tw (len) - (post-read-decode-fixed-euc-china len 'tw)) - -(make-coding-system 'fixed-euc-cn 5 ?W "Coding System for fixed EUC Chinese-gb2312") -(put 'fixed-euc-cn 'pre-write-conversion 'pre-write-encode-euc-cn) -(put 'fixed-euc-cn 'post-read-conversion 'post-read-decode-euc-cn) - -(make-coding-system 'fixed-euc-tw 5 ?W "Coding System for fixed EUC Chinese-cns11643") -(put 'fixed-euc-tw 'pre-write-conversion 'pre-write-encode-euc-tw) -(put 'fixed-euc-tw 'post-read-conversion 'post-read-decode-euc-tw) - -;;; euc-china.el ends here. diff --git a/euc-cn.el b/euc-cn.el deleted file mode 100644 index e001daa..0000000 --- a/euc-cn.el +++ /dev/null @@ -1,449 +0,0 @@ -;;; euc-cn.el --- Fixed EUC-CN handling routines. - -;; Copyright (C) 1997 Mule Project, -;; Powered by Electrotechnical Laboratory, JAPAN. -;; Project Leader: Satoru Tomura - -;; Author: KATAYAMA Yoshio -;; Maintainer: KATAYAMA Yoshio -;; Keywords: mule, multilingual, input method, chinese - -;; This file will be part of GNU Emacs (in future). - -;; GNU Emacs is free software; you can redistribute it and/or modify -;; it under the terms of the GNU General Public License as published by -;; the Free Software Foundation; either version 2, or (at your option) -;; any later version. - -;; GNU Emacs is distributed in the hope that it will be useful, -;; but WITHOUT ANY WARRANTY; without even the implied warranty of -;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -;; GNU General Public License for more details. - -;; You should have received a copy of the GNU General Public License -;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. - -;;; Commentary: - - -;;; Code: - -(defvar cwnn-zhuyin nil) - -(defconst chinese-sisheng-leading-chars - (concat (char-to-string (aref (charset-info 'chinese-sisheng) 6)) - (char-to-string (aref (charset-info 'chinese-sisheng) 7)))) -(defconst yincoding-pinyin-shengmu - '(("" . 0) ("B" . 1) ("C" . 2) ("Ch" . 3) ("D" . 4) - ("F" . 5) ("G" . 6) ("H" . 7) ("J" . 8) ("K" . 9) - ("L" . 10) ("M" . 11) ("N" . 12) ("P" . 13) ("Q" . 14) - ("R" . 15) ("S" . 16) ("Sh" . 17) ("T" . 18) ("W" . 19) - ("X" . 20) ("Y" . 21) ("Z" . 22) ("Zh" . 23))) - -(defconst yincoding-pinyin-yunmu - '(("(0@(B" 0) ("(0@(B" 0 0) ("(0@(B" 0 1) ("(0@(B" 0 2) ("(0@(B" 0 3) - ("a(0@(B" 1) ("(0!@(B" 1 0) ("(0"@(B" 1 1) ("(0#@(B" 1 2) ("(0$@(B" 1 3) - ("ai(0@(B" 2) ("(0!(Bi(0@(B" 2 0) ("(0"(Bi(0@(B" 2 1) ("(0#(Bi(0@(B" 2 2) ("(0$(Bi(0@(B" 2 3) - ("an(0@(B" 3) ("(0!(Bn(0@(B" 3 0) ("(0"(Bn(0@(B" 3 1) ("(0#(Bn(0@(B" 3 2) ("(0$(Bn(0@(B" 3 3) - ("ang(0@(B" 4) ("(0!(Bng(0@(B" 4 0) ("(0"(Bng(0@(B" 4 1) ("(0#(Bng(0@(B" 4 2) ("(0$(Bng(0@(B" 4 3) - ("ao(0@(B" 5) ("(0!(Bo(0@(B" 5 0) ("(0"(Bo(0@(B" 5 1) ("(0#(Bo(0@(B" 5 2) ("(0$(Bo(0@(B" 5 3) - ("e(0@(B" 6) ("(0%@(B" 6 0) ("(0&@(B" 6 1) ("(0'@(B" 6 2) ("(0(@(B" 6 3) - ("ei(0@(B" 7) ("(0%(Bi(0@(B" 7 0) ("(0&(Bi(0@(B" 7 1) ("(0'(Bi(0@(B" 7 2) ("(0((Bi(0@(B" 7 3) - ("en(0@(B" 8) ("(0%(Bn(0@(B" 8 0) ("(0&(Bn(0@(B" 8 1) ("(0'(Bn(0@(B" 8 2) ("(0((Bn(0@(B" 8 3) - ("eng(0@(B" 9) ("(0%(Bng(0@(B" 9 0) ("(0&(Bng(0@(B" 9 1) ("(0'(Bng(0@(B" 9 2) ("(0((Bng(0@(B" 9 3) - ("er(0@(B" 10) ("(0%(Br(0@(B" 10 0) ("(0&(Br(0@(B" 10 1) ("(0'(Br(0@(B" 10 2) ("(0((Br(0@(B" 10 3) - ("i(0@(B" 11) ("(0)@(B" 11 0) ("(0*@(B" 11 1) ("(0+@(B" 11 2) ("(0,@(B" 11 3) - ("ia(0@(B" 12) ("i(0!@(B" 12 0) ("i(0"@(B" 12 1) ("i(0#@(B" 12 2) ("i(0$@(B" 12 3) - ("ian(0@(B" 13) ("i(0!(Bn(0@(B" 13 0) ("i(0"(Bn(0@(B" 13 1) ("i(0#(Bn(0@(B" 13 2) ("i(0$(Bn(0@(B" 13 3) - ("iang(0@(B" 14) ("i(0!(Bng(0@(B" 14 0) ("i(0"(Bng(0@(B" 14 1) ("i(0#(Bng(0@(B" 14 2) ("i(0$(Bng(0@(B" 14 3) - ("iao(0@(B" 15) ("i(0!(Bo(0@(B" 15 0) ("i(0"(Bo(0@(B" 15 1) ("i(0#(Bo(0@(B" 15 2) ("i(0$(Bo(0@(B" 15 3) - ("ie(0@(B" 16) ("i(0%@(B" 16 0) ("i(0&@(B" 16 1) ("i(0'@(B" 16 2) ("i(0(@(B" 16 3) - ("in(0@(B" 17) ("(0)(Bn(0@(B" 17 0) ("(0*(Bn(0@(B" 17 1) ("(0+(Bn(0@(B" 17 2) ("(0,(Bn(0@(B" 17 3) - ("ing(0@(B" 18) ("(0)(Bng(0@(B" 18 0) ("(0*(Bng(0@(B" 18 1) ("(0+(Bng(0@(B" 18 2) ("(0,(Bng(0@(B" 18 3) - ("iong(0@(B" 19) ("i(0-(Bng(0@(B" 19 0) ("i(0.(Bng(0@(B" 19 1) ("i(0/(Bng(0@(B" 19 2) ("i(00(Bng(0@(B" 19 3) - ("iu(0@(B" 20) ("i(01@(B" 20 0) ("i(02@(B" 20 1) ("i(03@(B" 20 2) ("i(04@(B" 20 3) - ("m(0@(B" 21) ("m(0@(B" 21 0) ("m(0@(B" 21 1) ("m(0@(B" 21 2) ("m(0@(B" 21 3) - ("n(0@(B" 22) ("n(0@(B" 22 0) ("(0=@(B" 22 1) ("(0>@(B" 22 2) ("(0?@(B" 22 3) - ("ng(0@(B" 23) ("ng(0@(B" 23 0) ("ng(0@(B" 23 1) ("ng(0@(B" 23 2) ("ng(0@(B" 23 3) - ("o(0@(B" 24) ("(0-@(B" 24 0) ("(0.@(B" 24 1) ("(0/@(B" 24 2) ("(00@(B" 24 3) - ("ong(0@(B" 25) ("(0-(Bng(0@(B" 25 0) ("(0.(Bng(0@(B" 25 1) ("(0/(Bng(0@(B" 25 2) ("(00(Bng(0@(B" 25 3) - ("ou(0@(B" 26) ("(0-(Bu(0@(B" 26 0) ("(0.(Bu(0@(B" 26 1) ("(0/(Bu(0@(B" 26 2) ("(00(Bu(0@(B" 26 3) - ("u(0@(B" 27) ("(01@(B" 27 0) ("(02@(B" 27 1) ("(03@(B" 27 2) ("(04@(B" 27 3) - ("ua(0@(B" 28) ("u(0!@(B" 28 0) ("u(0"@(B" 28 1) ("u(0#@(B" 28 2) ("u(0$@(B" 28 3) - ("uai(0@(B" 29) ("u(0!(Bi(0@(B" 29 0) ("u(0"(Bi(0@(B" 29 1) ("u(0#(Bi(0@(B" 29 2) ("u(0$(Bi(0@(B" 29 3) - ("uan(0@(B" 30) ("u(0!(Bn(0@(B" 30 0) ("u(0"(Bn(0@(B" 30 1) ("u(0#(Bn(0@(B" 30 2) ("u(0$(Bn(0@(B" 30 3) - ("uang(0@(B" 31) ("u(0!(Bng(0@(B" 31 0) ("u(0"(Bng(0@(B" 31 1) ("u(0#(Bng(0@(B" 31 2) ("u(0$(Bng(0@(B" 31 3) - ("ue(0@(B" 32) ("u(0%@(B" 32 0) ("u(0&@(B" 32 1) ("u(0'@(B" 32 2) ("u(0(@(B" 32 3) - ("ui(0@(B" 33) ("u(0)@(B" 33 0) ("u(0*@(B" 33 1) ("u(0+@(B" 33 2) ("u(0,@(B" 33 3) - ("un(0@(B" 34) ("(01(Bn(0@(B" 34 0) ("(02(Bn(0@(B" 34 1) ("(03(Bn(0@(B" 34 2) ("(04(Bn(0@(B" 34 3) - ("uo(0@(B" 35) ("u(0-@(B" 35 0) ("u(0.@(B" 35 1) ("u(0/@(B" 35 2) ("u(00@(B" 35 3) - ("(09@(B" 36) ("(05@(B" 36 0) ("(06@(B" 36 1) ("(07@(B" 36 2) ("(08@(B" 36 3) - ("(09(Be(0@(B" 37) ("(09%@(B" 37 0) ("(09&@(B" 37 1) ("(09'@(B" 37 2) ("(09(@(B" 37 3) - ("0(0@(B" 38) ("1(0@(B" 38 0) ("2(0@(B" 38 1) ("3(0@(B" 38 2) ("4(0@(B" 38 3))) - -(defconst yincoding-pinyin-table - [ - 0 1 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 1 1 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 - 0 1 1 1 1 1 0 1 1 1 0 1 0 1 0 1 1 1 1 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0 0 0 0 1 - 0 1 1 1 1 1 1 1 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 0 0 1 0 0 1 1 1 0 0 1 - 0 1 1 1 1 1 1 0 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 0 1 1 1 0 0 1 - 0 1 1 1 1 1 1 1 1 1 0 1 1 1 0 1 1 0 1 0 1 0 0 0 0 1 1 1 0 0 1 0 0 1 1 1 0 0 1 - 0 1 0 1 1 0 0 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 1 1 0 0 0 0 0 0 0 0 0 0 1 - 0 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 0 1 1 1 0 0 1 - 0 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 1 0 1 0 1 1 1 1 1 1 1 0 1 1 1 0 0 1 - 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 1 0 0 1 0 1 0 1 0 0 0 1 - 0 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 0 1 1 1 0 0 1 - 0 1 1 1 1 1 1 1 0 1 0 1 1 1 1 1 1 1 1 0 1 0 0 0 1 1 1 1 0 0 1 0 0 0 1 1 1 1 1 - 0 1 1 1 1 1 1 1 1 1 0 1 0 1 0 1 1 1 1 0 1 0 0 0 1 0 1 1 0 0 0 0 0 0 0 0 0 0 1 - 0 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 1 1 1 0 1 0 0 0 0 1 1 1 0 0 1 0 0 0 0 1 1 1 1 - 0 1 1 1 1 1 0 1 1 1 0 1 0 1 0 1 1 1 1 0 0 0 0 0 1 0 1 1 0 0 0 0 0 0 0 0 0 0 1 - 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 1 0 0 1 0 1 0 1 0 0 0 1 - 0 0 0 1 1 1 1 0 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 0 1 0 0 1 1 1 0 0 1 - 0 1 1 1 1 1 1 0 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 0 0 1 0 0 1 1 1 0 0 1 - 0 1 1 1 1 1 1 1 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 0 1 1 1 0 0 1 - 0 1 1 1 1 1 1 1 0 1 0 1 0 1 0 1 1 0 1 0 0 0 0 0 0 1 1 1 0 0 1 0 0 1 1 1 0 0 1 - 0 1 1 1 1 0 0 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0 0 0 0 1 - 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 1 0 0 1 0 1 0 1 0 0 0 1 - 0 1 0 1 1 1 1 0 0 0 0 1 0 0 0 0 0 1 1 0 0 0 0 0 1 1 1 1 0 0 1 0 1 0 1 0 0 0 1 - 0 1 1 1 1 1 1 1 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 0 0 1 0 0 1 1 1 0 0 1 - 0 1 1 1 1 1 1 1 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 0 1 1 1 0 0 1 - ]) - -(defconst yincoding-zhuyin-length (charset-bytes 'chinese-sisheng)) - -(defconst yincoding-zhuyin-shengmu - '(("" . 0) ("(0E(B" . 1) ("(0X(B" . 2) ("(0T(B" . 3) ("(0I(B" . 4) - ("(0H(B" . 5) ("(0M(B" . 6) ("(0O(B" . 7) ("(0P(B" . 8) ("(0N(B" . 9) - ("(0L(B" . 10) ("(0G(B" . 11) ("(0K(B" . 12) ("(0F(B" . 13) ("(0Q(B" . 14) - ("(0V(B" . 15) ("(0Y(B" . 16) ("(0U(B" . 17) ("(0J(B" . 18) ("(0h(B" . 19) - ("(0R(B" . 20) ("(0g(B" . 21) ("(0W(B" . 22) ("(0S(B" . 23))) - -(defconst yincoding-zhuyin-yunmu - '(("(0@(B" 0) ("(0A(B" 0 0) ("(0B(B" 0 1) ("(0C(B" 0 2) ("(0D(B" 0 3) ; i - ("(0Z@(B" 1) ("(0ZA(B" 1 0) ("(0ZB(B" 1 1) ("(0ZC(B" 1 2) ("(0ZD(B" 1 3) ; a - ("(0^@(B" 2) ("(0^A(B" 2 0) ("(0^B(B" 2 1) ("(0^C(B" 2 2) ("(0^D(B" 2 3) ; ai - ("(0b@(B" 3) ("(0bA(B" 3 0) ("(0bB(B" 3 1) ("(0bC(B" 3 2) ("(0bD(B" 3 3) ; an - ("(0d@(B" 4) ("(0dA(B" 4 0) ("(0dB(B" 4 1) ("(0dC(B" 4 2) ("(0dD(B" 4 3) ; ang - ("(0`@(B" 5) ("(0`A(B" 5 0) ("(0`B(B" 5 1) ("(0`C(B" 5 2) ("(0`D(B" 5 3) ; ao - ("(0\@(B" 6) ("(0\A(B" 6 0) ("(0\B(B" 6 1) ("(0\C(B" 6 2) ("(0\D(B" 6 3) ; e - ("(0_@(B" 7) ("(0_A(B" 7 0) ("(0_B(B" 7 1) ("(0_C(B" 7 2) ("(0_D(B" 7 3) ; ei - ("(0c@(B" 8) ("(0cA(B" 8 0) ("(0cB(B" 8 1) ("(0cC(B" 8 2) ("(0cD(B" 8 3) ; en - ("(0e@(B" 9) ("(0eA(B" 9 0) ("(0eB(B" 9 1) ("(0eC(B" 9 2) ("(0eD(B" 9 3) ; eng - ("(0f@(B" 10) ("(0fA(B" 10 0) ("(0fB(B" 10 1) ("(0fC(B" 10 2) ("(0fD(B" 10 3) ; er - ("(0g@(B" 11) ("(0gA(B" 11 0) ("(0gB(B" 11 1) ("(0gC(B" 11 2) ("(0gD(B" 11 3) ; i - ("(0gZ@(B" 12) ("(0gZA(B" 12 0) ("(0gZB(B" 12 1) ("(0gZC(B" 12 2) ("(0gZD(B" 12 3) ; ia - ("(0gb@(B" 13) ("(0gbA(B" 13 0) ("(0gbB(B" 13 1) ("(0gbC(B" 13 2) ("(0gbD(B" 13 3) ; ian - ("(0gd@(B" 14) ("(0gdA(B" 14 0) ("(0gdB(B" 14 1) ("(0gdC(B" 14 2) ("(0gdD(B" 14 3) ; iang - ("(0g`@(B" 15) ("(0g`A(B" 15 0) ("(0g`B(B" 15 1) ("(0g`C(B" 15 2) ("(0g`D(B" 15 3) ; iao - ("(0g]@(B" 16) ("(0g]A(B" 16 0) ("(0g]B(B" 16 1) ("(0g]C(B" 16 2) ("(0g]D(B" 16 3) ; ie - ("(0gc@(B" 17) ("(0gcA(B" 17 0) ("(0gcB(B" 17 1) ("(0gcC(B" 17 2) ("(0gcD(B" 17 3) ; in - ("(0ge@(B" 18) ("(0geA(B" 18 0) ("(0geB(B" 18 1) ("(0geC(B" 18 2) ("(0geD(B" 18 3) ; ing - ("(0ie@(B" 19) ("(0ieA(B" 19 0) ("(0ieB(B" 19 1) ("(0ieC(B" 19 2) ("(0ieD(B" 19 3) ; iong - ("(0ga@(B" 20) ("(0gaA(B" 20 0) ("(0gaB(B" 20 1) ("(0gaC(B" 20 2) ("(0gaD(B" 20 3) ; iu - ("(0G@(B" 21) ("(0GA(B" 21 0) ("(0GB(B" 21 1) ("(0GC(B" 21 2) ("(0GD(B" 21 3) ; m - ("(0K@(B" 22) ("(0KA(B" 22 0) ("(0KB(B" 22 1) ("(0KC(B" 22 2) ("(0KD(B" 22 3) ; n - ("@(0@(B" 23) ("@(0A(B" 23 0) ("@(0B(B" 23 1) ("@(0C(B" 23 2) ("@(0D(B" 23 3) ; ng - ("(0[@(B" 24) ("(0[A(B" 24 0) ("(0[B(B" 24 1) ("(0[C(B" 24 2) ("(0[D(B" 24 3) ; o - ("(0he@(B" 25) ("(0heA(B" 25 0) ("(0heB(B" 25 1) ("(0heC(B" 25 2) ("(0heD(B" 25 3) ; ong - ("(0a@(B" 26) ("(0aA(B" 26 0) ("(0aB(B" 26 1) ("(0aC(B" 26 2) ("(0aD(B" 26 3) ; ou - ("(0h@(B" 27) ("(0hA(B" 27 0) ("(0hB(B" 27 1) ("(0hC(B" 27 2) ("(0hD(B" 27 3) ; u - ("(0hZ@(B" 28) ("(0hZA(B" 28 0) ("(0hZB(B" 28 1) ("(0hZC(B" 28 2) ("(0hZD(B" 28 3) ; ua - ("(0h^@(B" 29) ("(0h^A(B" 29 0) ("(0h^B(B" 29 1) ("(0h^C(B" 29 2) ("(0h^D(B" 29 3) ; uai - ("(0hb@(B" 30) ("(0hbA(B" 30 0) ("(0hbB(B" 30 1) ("(0hbC(B" 30 2) ("(0hbD(B" 30 3) ; uan - ("(0hd@(B" 31) ("(0hdA(B" 31 0) ("(0hdB(B" 31 1) ("(0hdC(B" 31 2) ("(0hdD(B" 31 3) ; uang - ("(0i]@(B" 37) ("(0i]A(B" 37 0) ("(0i]B(B" 37 1) ("(0i]C(B" 37 2) ("(0i]D(B" 37 3) ; ue - ("(0h_@(B" 33) ("(0h_A(B" 33 0) ("(0h_B(B" 33 1) ("(0h_C(B" 33 2) ("(0h_D(B" 33 3) ; ui - ("(0hc@(B" 34) ("(0hcA(B" 34 0) ("(0hcB(B" 34 1) ("(0hcC(B" 34 2) ("(0hcD(B" 34 3) ; un - ("(0h[@(B" 35) ("(0h[A(B" 35 0) ("(0h[B(B" 35 1) ("(0h[C(B" 35 2) ("(0h[D(B" 35 3) ; uo - ("(0i@(B" 36) ("(0iA(B" 36 0) ("(0iB(B" 36 1) ("(0iC(B" 36 2) ("(0iD(B" 36 3) ; (09(B - ("(0i]@(B" 37) ("(0i]A(B" 37 0) ("(0i]B(B" 37 1) ("(0i]C(B" 37 2) ("(0i]D(B" 37 3) ; (09(Be - ("0(0@(B" 38) ("1(0A(B" 38 0) ("2(0B(B" 38 1) ("3(0C(B" 38 2) ("4(0D(B" 38 3) ; undefined YunMu - ("(0ib@(B" 39) ("(0ibA(B" 39 0) ("(0ibB(B" 39 1) ("(0ibC(B" 39 2) ("(0ibD(B" 39 3) ; (09(Ban - ("(0ic@(B" 40) ("(0icA(B" 40 0) ("(0icB(B" 40 1) ("(0icC(B" 40 2) ("(0icD(B" 40 3) ; (09(Bn - )) - -(defconst yincoding-zhuyin-table - [ - ;; empty ShengMu - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x9586 ?\x0000 ?\x9592 ?\x9599 - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x959b ?\x95a0 ?\x0000 ?\x959e - ?\x95a2 - ;; ShengMu B - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu C - ?\x828b ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x0280 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu Ch - ?\x838b ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 - ?\x0000 ?\x0380 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu D - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu F - ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu G - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu H - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu J - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x08a4 ?\x0000 ?\x0000 - ?\x08a7 ?\x0000 ?\x08a5 ?\x0000 ?\x08a8 ?\x0000 ?\x889b ?\x88a0 ?\x8000 ?\x889e - ?\x88a2 - ;; ShengMu K - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu L - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu M - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu N - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu P - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu Q - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0ea4 ?\x0000 ?\x0000 - ?\x0ea7 ?\x0000 ?\x0ea5 ?\x0000 ?\x0ea8 ?\x0000 ?\x8e9b ?\x8ea0 ?\x8000 ?\x8e9e - ?\x8ea2 - ;; ShengMu R - ?\x8f8b ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 - ?\x0000 ?\x0f80 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu S - ?\x908b ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 - ?\x0000 ?\x1080 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu Sh - ?\x918b ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x1180 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu T - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 - ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu W - ?\x939b ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 ?\x0000 ?\x1380 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu X - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x14a4 ?\x0000 ?\x0000 - ?\x14a7 ?\x0000 ?\x14a5 ?\x0000 ?\x14a8 ?\x0000 ?\x949b ?\x94a0 ?\x8000 ?\x949e - ?\x94a2 - ;; ShengMu Y - ?\x958b ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0090 ?\x0000 ?\x9591 ?\x9592 - ?\x0000 ?\x1580 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x1588 ?\x1589 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0093 ?\x8000 ?\x00a4 ?\x0000 ?\x0000 - ?\x00a7 ?\x0000 ?\x00a5 ?\x0000 ?\x00a8 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu Z - ?\x968b ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x1680 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 - ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ;; ShengMu Zh - ?\x978b ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x0000 ?\x1780 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 - ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 ?\x8000 - ?\x8000 ?\x8000 ?\x0000 ?\x8000 ?\x8000 ?\x8000 ?\x0000 ?\x0000 ?\x8000 ?\x0000 - ?\x0000 - ]) - -(defun encode-euc-cwnn-region (beg end) - "Encode the text in the current region to EUC-cWnn. -Return the length of resulting text." - (interactive "r") - (let (sylend s y z (enable-multibyte-characters t)) - (save-excursion - (save-restriction - (narrow-to-region beg end) - (goto-char (point-min)) - (while (< (point) (point-max)) - (cond - ((looking-at "[A-Za-z(0!(B-(0?(B]+(0@(B") - ;; PinYin - (setq sylend (match-end 0)) - (if (and (looking-at "[B-Z]h?") - (setq s (assoc (buffer-substring (match-beginning 0) (match-end 0)) - yincoding-pinyin-shengmu))) - (setq s (cdr s) y (buffer-substring (match-end 0) sylend)) - (setq s 0 y (buffer-substring (point) sylend))) - (if (and (setq y (assoc y yincoding-pinyin-yunmu)) - (= (aref yincoding-pinyin-table (+ (* 39 s) (nth 1 y))) 1)) - (progn - (delete-region (point) sylend) - (insert (char-to-string (+ (* 2 (nth 1 y)) 32 (if (nth 2 y) 1 0))) - (char-to-string (+ (* 4 (if (= s 0) 20 s)) 156 (if (nth 2 y) (nth 2 y) 0))))) - (encode-euc-cwnn-1-char))) - ((looking-at "[(0E(B-(0i(B@0-4]+[(0@ABCD(B]") - ;; ZhuYin - (setq sylend (match-end 0)) - (if (setq y (assoc (buffer-substring (point) sylend) yincoding-zhuyin-yunmu)) - (setq s 0) - (if (setq s (assoc (char-to-string (following-char)) yincoding-zhuyin-shengmu)) - (setq s (cdr s) y (buffer-substring (+ (point) yincoding-zhuyin-length) sylend)) - (setq s 0 y (buffer-substring (point) sylend))) - (setq y (assoc y yincoding-zhuyin-yunmu))) - (if (and y - (/= (logand (setq z (aref yincoding-zhuyin-table (+ (* 41 s) (nth 1 y)))) ?\x8000) 0)) - (progn - (delete-region (point) sylend) - (if (/= (logand z ?\x80) 0) - (setq s (logand (lsh z -8) 127) y (list nil (logand z 127) (nth 2 y)))) - (insert (+ (* 2 (nth 1 y)) 32 (if (nth 2 y) 1 0)) - (+ (* 4 (if (= s 0) 20 s)) 156 (if (nth 2 y) (nth 2 y) 0)))) - (encode-euc-cwnn-1-char))) - (t (encode-euc-cwnn-1-char)))) - (- (point-max) (point-min)))))) - -(defun encode-euc-cwnn-1-char () - (let ((enable-multibyte-characters nil)) - (cond - ((eq (following-char) (charset-id 'chinese-gb2312)) - (delete-char 1) - (forward-char 2)) - ((looking-at chinese-sisheng-leading-chars) - (delete-region (match-beginning 0) (match-end 0)) - (insert 0) - (forward-char)) - (t - (insert 0) - (forward-char))))) - -(defun pre-write-encode-euc-cwnn (from to) - (let ((buf (current-buffer)) - (work (get-buffer-create " *pre-write-encoding-work*"))) - (set-buffer work) - (erase-buffer) - (if (stringp from) - (insert from) - (insert-buffer-substring buf from to)) - (encode-euc-cwnn-region 1 (point-max)) - nil)) - -(defun decode-euc-cwnn-region (beg end) - "Decode EUC-cWnn encoded text in the current region. -Return the length of resulting text." - (interactive "r") - (prog1 - (let (c cc s y ss (enable-multibyte-characters nil)) - (save-restriction - (narrow-to-region beg end) - (goto-char (point-min)) - (while (< (point) (point-max)) - (setq c (following-char)) - (cond - ((eq c 0) - (delete-char 1) - (if (>= (following-char) 128) - (insert chinese-sisheng-leading-chars)) - (forward-char)) - ((>= c 128) - (insert (charset-id 'chinese-gb2312)) - (forward-char 2) - (if (< (setq c (preceding-char)) 128) - (progn - (delete-char -1) - (insert (+ c 128)) - (forward-char)))) - (t - (delete-char 1) - (setq cc (logand (following-char) 127)) - (delete-char 1) - (setq s (+ (lsh (- cc 32) -2) 1) - y (lsh (- c 32) -1) - ss (+ (logand c 1) (logand cc 3))) - (if cwnn-zhuyin - (progn - (setq c (aref yincoding-zhuyin-table (+ (* 41 s) y))) - (if (eq (logand c ?\x8080) ?\x80) - (setq s (lsh c -8) - y (logand c 127))) - (if (and (eq s 20) - (eq (aref yincoding-pinyin-table (+ (* 39 s) y)) 0)) - (setq s 0)) - (insert (car (nth s yincoding-zhuyin-shengmu)) - (car (nth (+ (* 5 y) ss) yincoding-zhuyin-yunmu)))) - (if (and (eq s 20) - (eq (aref yincoding-pinyin-table (+ (* 39 s) y)) 0)) - (setq s 0)) - (insert (car (nth s yincoding-pinyin-shengmu)) - (car (nth (+ (* 5 y) ss) yincoding-pinyin-yunmu))))))) - (- (point-max) (point-min)))) - (if (looking-at "\0\0") (forward-char 2)))) - -(defun post-read-decode-euc-cwnn (len) - (let ((pos (point)) - (buffer-modified-p (buffer-modified-p))) - (prog1 - (decode-euc-cwnn-region pos (+ pos len)) - (set-buffer-modified-p buffer-modified-p)))) - -(make-coding-system 'fixed-euc-cn 5 ?W "Coding System for fixed EUC Japanese") -(put 'fixed-euc-cn 'post-read-conversion 'post-read-decode-euc-cwnn) -(put 'fixed-euc-cn 'pre-write-conversion 'pre-write-encode-euc-cwnn) - -;;; euc-cn.el ends here. diff --git a/its/ascii.el b/its/ascii.el deleted file mode 100644 index 272a340..0000000 --- a/its/ascii.el +++ /dev/null @@ -1,55 +0,0 @@ -;;; its/ascii.el --- ASCII Input in Egg Input Method Architecture - -;; Copyright (C) 1997, 1998 Mule Project, -;; Powered by Electrotechnical Laboratory, JAPAN. -;; Project Leader: Satoru Tomura - -;; Author: KATAYAMA Yoshio - -;; This file will be part of GNU Emacs (in future). - -;; GNU Emacs is free software; you can redistribute it and/or modify -;; it under the terms of the GNU General Public License as published by -;; the Free Software Foundation; either version 2, or (at your option) -;; any later version. - -;; GNU Emacs is distributed in the hope that it will be useful, -;; but WITHOUT ANY WARRANTY; without even the implied warranty of -;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -;; GNU General Public License for more details. - -;; You should have received a copy of the GNU General Public License -;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. - -;;; Commentary: -;; -;; Symbol input is desined by jiro@math.keio.ac.jp (TANAKA Jiro) -;; This file is based on the rules of its/hira.el in Mule-2.3 distribution. -;; - -;;; Code: - -(eval-when-compile - (require 'its)) - -(define-its-state-machine its-up-map - "upcase" "aA" nil nil - "Map for upcase input." - - (let ((i ? )) - (while (<= i ?~) - (its-defrule (char-to-string i) (upcase (char-to-string i))) - (setq i (1+ i))))) - -(define-its-state-machine its-down-map - "downcase" "aa" nil nil - "Map for downcase input." - - (let ((i ? )) - (while (<= i ?~) - (its-defrule (char-to-string i) (char-to-string i)) - (setq i (1+ i))))) - -(provide 'its/ascii) diff --git a/its/erpin.el b/its/erpin.el deleted file mode 100644 index db0665b..0000000 --- a/its/erpin.el +++ /dev/null @@ -1,387 +0,0 @@ -(eval-when-compile - (require 'its) - (require 'cl)) - -(defvar its-erpin-cn-enable-quanjioao-alphabet t "*Enable Quanjiao alphabet") -(defvar its-erpin-cn-open-braket "$A!8(B" "*[") ; "$A#[(B" -(defvar its-erpin-cn-close-braket "$A!9(B" "*]") ; "$A#](B" - -(defvar its-erpin-tw-enable-quanjioao-alphabet t "*Enable Quanjiao alphabet") -(defvar its-erpin-tw-open-braket "$(G!V(B" "*[") ; "$(G!b(B " -(defvar its-erpin-tw-close-braket "$(G!W(B" "*]") ; "$(G!c(B" - -(eval-when-compile - (defsubst its-defoutput* (input display) - (its-set-output (its-goto-state input nil t) display)) - - (defun its-define-erpin-qingsheng (shengmu yunmu &optional y) - (let ((input (concat (car shengmu) yunmu)) - (output (concat (cdr shengmu) (if y y yunmu) "(0@(B")) - state) - (setq state (its-goto-state input nil t)) - (its-set-output state output) - (its-make-next-state state -1 input output) - (its-make-next-state state ? (concat input " ") output) - (its-make-next-state state ?0 (concat input "0") output) - (its-define-otherwise state (its-make-otherwise output - its-otherwise-back-one)) - state)) - - (defmacro its-do-erpin-table (list) - `(progn - ,@(mapcar (lambda (syl) - `(its-define-erpin ,(car syl) ,(cdr syl))) - list))) - - (defmacro its-define-erpin (shengmu yunmu) - `(let ((y1 (nth 1 ,yunmu)) (y2 (nth 2 ,yunmu)) (y3 (nth 3 ,yunmu)) - (y4 (nth 4 ,yunmu)) (y5 (nth 5 ,yunmu)) (y (car ,yunmu)) - (ss (list ,@shengmu)) sa sd state) - (while ss - (setq sa (caar ss) sd (cdar ss) - state (its-define-erpin-qingsheng (car ss) y y5)) - (its-make-next-state state ?1 (concat sa y 1) (concat sd y1 "(0@(B")) - (its-make-next-state state ?2 (concat sa y 2) (concat sd y2 "(0@(B")) - (its-make-next-state state ?3 (concat sa y 3) (concat sd y3 "(0@(B")) - (its-make-next-state state ?4 (concat sa y 4) (concat sd y4 "(0@(B")) - (setq ss (cdr ss))))) - - (defmacro its-define-erpin-table () - '(let ((O '("o" . "")) (B '("b" . "B")) (C '("c" . "C")) (D '("d" . "D")) - (F '("f" . "F")) (G '("g" . "G")) (H '("h" . "H")) (J '("j" . "J")) - (K '("k" . "K")) (L '("l" . "L")) (M '("m" . "M")) (N '("n" . "N")) - (P '("p" . "P")) (Q '("q" . "Q")) (R '("r" . "R")) (S '("s" . "S")) - (T '("t" . "T")) (W '("w" . "W")) (X '("x" . "X")) (Y '("y" . "Y")) - (Z '("z" . "Z")) - (I '("i" . "Ch")) (U '("u" . "Sh")) (V '("v" . "Zh")) - - (a '("a" "(0!(B" "(0"(B" "(0#(B" "(0$(B" "a" )) - (ai '("s" "(0!(Bi" "(0"(Bi" "(0#(Bi" "(0$(Bi" "ai" )) - (an '("f" "(0!(Bn" "(0"(Bn" "(0#(Bn" "(0$(Bn" "an" )) - (ang '("g" "(0!(Bng" "(0"(Bng" "(0#(Bng" "(0$(Bng" "ang" )) - (ao '("d" "(0!(Bo" "(0"(Bo" "(0#(Bo" "(0$(Bo" "ao" )) - (e '("e" "(0%(B" "(0&(B" "(0'(B" "(0((B" "e" )) - (ei '("w" "(0%(Bi" "(0&(Bi" "(0'(Bi" "(0((Bi" "ei" )) - (en '("r" "(0%(Bn" "(0&(Bn" "(0'(Bn" "(0((Bn" "en" )) - (eng '("t" "(0%(Bng" "(0&(Bng" "(0'(Bng" "(0((Bng" "eng" )) - (er '("y" "(0%(Br" "(0&(Br" "(0'(Br" "(0((Br" "er" )) - (i '("i" "(0)(B" "(0*(B" "(0+(B" "(0,(B" "i" )) - (ia '("p" "i(0!(B" "i(0"(B" "i(0#(B" "i(0$(B" "ia" )) - (ian '("h" "i(0!(Bn" "i(0"(Bn" "i(0#(Bn" "i(0$(Bn" "ian" )) - (iang '("j" "i(0!(Bng" "i(0"(Bng" "i(0#(Bng" "i(0$(Bng" "iang")) - (iao '("k" "i(0!(Bo" "i(0"(Bo" "i(0#(Bo" "i(0$(Bo" "iao" )) - (ie '("l" "i(0%(B" "i(0&(B" "i(0'(B" "i(0((B" "ie" )) - (in '("m" "(0)(Bn" "(0*(Bn" "(0+(Bn" "(0,(Bn" "in" )) - (ing '("n" "(0)(Bng" "(0*(Bng" "(0+(Bng" "(0,(Bng" "ing" )) - (iong '("b" "i(0-(Bng" "i(0.(Bng" "i(0/(Bng" "i(00(Bng" "iong")) - (iu '("y" "i(01(B" "i(02(B" "i(03(B" "i(04(B" "iu" )) - (o '("o" "(0-(B" "(0.(B" "(0/(B" "(00(B" "o" )) - (ong '("b" "(0-(Bng" "(0.(Bng" "(0/(Bng" "(00(Bng" "ong" )) - (ou '("q" "(0-(Bu" "(0.(Bu" "(0/(Bu" "(00(Bu" "ou" )) - (u '("u" "(01(B" "(02(B" "(03(B" "(04(B" "u" )) - (v '("v" "(05(B" "(06(B" "(07(B" "(08(B" "(09(B" )) - (ua '("p" "u(0!(B" "u(0"(B" "u(0#(B" "u(0$(B" "ua" )) - (uai '("k" "u(0!(Bi" "u(0"(Bi" "u(0#(Bi" "u(0$(Bi" "uai" )) - (uan '("x" "u(0!(Bn" "u(0"(Bn" "u(0#(Bn" "u(0$(Bn" "uan" )) - (uang '("j" "u(0!(Bng" "u(0"(Bng" "u(0#(Bng" "u(0$(Bng" "uang")) - (ue '("c" "u(0%(B" "u(0&(B" "u(0'(B" "u(0((B" "ue" )) - (ve '("c" "(09%(B" "(09&(B" "(09'(B" "(09((B" "(09(Be" )) - (ui '("c" "u(0)(B" "u(0*(B" "u(0+(B" "u(0,(B" "ui" )) - (un '("z" "(01(Bn" "(02(Bn" "(03(Bn" "(04(Bn" "un" )) - (uo '("o" "u(0-(B" "u(0.(B" "u(0/(B" "u(00(B" "uo" ))) - - (dolist (SHENG (list B C D F G H J K L M N P Q R S T W X Y Z I U V)) - (its-defrule (car SHENG) (cdr SHENG))) - - (its-do-erpin-table - (((O B C D F G H K L M N P S T W Y Z I U V) . a) - ((O B C D G H K L M N P S T W Z I U V) . ai) - ((O B C D F G H K L M N P R S T W Y Z I U V) . an) - ((O B C D F G H K L M N P R S T W Y Z I U V) . ang) - ((O B C D G H K L M N P R S T Y Z I U V) . ao) - ((O C D G H K L M N R S T Y Z I U V) . e) - ((O B C D F G H K L M N P T W Z U V) . ei) - ((O B C D F G H K M N P R S W Z I U V) . en) - ((O B C D F G H K L M N P R S T W Z I U V) . eng) - ((O ) . er) - (( B C D J L M N P Q R S T X Y Z I U V) . i) - (( D J L Q X ) . ia) - (( B D J L M N P Q T X ) . ian) - (( J L N Q X ) . iang) - (( B D J L M N P Q T X ) . iao) - (( B D J L M N P Q T X ) . ie) - (( B J L M N P Q X Y ) . in) - (( B D J L M N P Q T X Y ) . ing) - (( J Q X ) . iong) - (( D J L M N Q X ) . iu) - ((O B F M P W Y ) . o) - (( C D G H K L N R S T Y Z I V) . ong) - ((O C D F G H K L M N P R S T Y Z I U V) . ou) - (( B C D F G H J K L M N P Q R S T W X Y Z I U V) . u) - (( L N ) . v) - (( G H K R I U V) . ua) - (( G H K I U V) . uai) - (( C D G H J K L N Q R S T X Y Z I U V) . uan) - (( G H K I U V) . uang) - (( J Q X Y ) . ue) - (( L N ) . ve) - (( C D G H K R S T Z I U V) . ui) - (( C D G H J K L Q R S T X Y Z I U V) . un) - (( C D G H K L N R S T Z I U V) . uo) - - (('("" . "")) . (cons "er" (cdr er))) - - ((J Q X) . (cons "a" (cdr ia ))) - ((J Q X) . (cons "s" (cdr ia ))) - ((J Q X) . (cons "f" (cdr ian ))) - ((J Q X) . (cons "g" (cdr iang))) - ((J Q X) . (cons "d" (cdr iao ))) - ((J Q X) . (cons "e" (cdr ie ))) - ((J Q X) . (cons "w" (cdr ie ))) - ((J Q X) . (cons "r" (cdr in ))) - ((J Q X) . (cons "t" (cdr ing ))) - ((J Q X) . (cons "q" (cdr iu ))))) - - (its-define-erpin-qingsheng H "m") - (its-define-erpin-qingsheng H "n" "ng") - (its-define-erpin-qingsheng O "m") - (its-define-erpin-qingsheng O "n") - - (its-defrule "on5" "ng(0@(B") - (its-defrule "on2" "(0=@(B") - (its-defrule "on3" "(0>@(B") - (its-defrule "on4" "(0?@(B")))) - -(define-its-state-machine its-erpin-cn-map - "erpin-cn" "$A6~(BG" "Chinese-GB" - "Map for Erpin input. (Chinese-GB)" - - (defconst its-quanjiao-escape "Z") - (defconst its-banjiao-escape "X") - - (its-defrule-select-mode-temporally "B" downcase) - (its-defrule-select-mode-temporally "Q" quanjiao-downcase-cn) - - (its-define-erpin-table) - (its-defoutput* "b " "$A2;(B") - (its-defoutput* "c " "$A2E(B") - (its-defoutput* "ch " "$A3v(B") - (its-defoutput* "d " "$A5D(B") - (its-defoutput* "f " "$A74(B") - (its-defoutput* "g " "$A8v(B") - (its-defoutput* "h " "$A:M(B") - (its-defoutput* "i " "$AR;(B") - (its-defoutput* "j " "$A>M(B") - (its-defoutput* "k " "$A?I(B") - (its-defoutput* "l " "$AAK(B") - (its-defoutput* "m " "$AC?(B") - (its-defoutput* "n " "$ADj(B") - (its-defoutput* "p " "$AEz(B") - (its-defoutput* "q " "$AH%(B") - (its-defoutput* "r " "$AHU(B") - (its-defoutput* "s " "$AJG(B") - (its-defoutput* "u " "$AIO(B") - (its-defoutput* "t " "$AK{(B") - (its-defoutput* "w " "$ANR(B") - (its-defoutput* "x " "$AOr(B") - (its-defoutput* "y " "$ASV(B") - (its-defoutput* "z " "$ATZ(B") - (its-defoutput* "v " "$AWE(B") - - (dolist (ascii '(("0" . "$A#0(B") ("1" . "$A#1(B") ("2" . "$A#2(B") ("3" . "$A#3(B") - ("4" . "$A#4(B") ("5" . "$A#5(B") ("6" . "$A#6(B") ("7" . "$A#7(B") - ("8" . "$A#8(B") ("9" . "$A#9(B") - (" " . "$A!!(B") ("!" . "$A#!(B") ("@" . "$A#@(B") ("#" . "$A##(B") - ("$" . "$A!g(B") ("%" . "$A#%(B") ("^" . "$A#^(B") ("&" . "$A#&(B") - ("*" . "$A#*(B") ("(" . "$A#((B") (")" . "$A#)(B") - ("-" . "$A#-(B") ("=" . "$A#=(B") ("`" . "$A#`(B") ("\\" . "$A#\(B") - ("|" . "$A#|(B") ("_" . "$A#_(B") ("+" . "$A#+(B") ("~" . "$A!+(B") - ("[" . "$A#[(B") ("]" . "$A#](B") ("{" . "$A#{(B") ("}" . "$A#}(B") - (":" . "$A#:(B") (";" . "$A#;(B") ("\"" . "$A#"(B") ("'" . "$A#'(B") - ("<" . "$A#<(B") (">" . "$A#>(B") ("?" . "$A#?(B") ("/" . "$A#/(B") - ("," . "$A#,(B") ("." . "$A#.(B") - ("a" . "$A#a(B") ("b" . "$A#b(B") ("c" . "$A#c(B") ("d" . "$A#d(B") - ("e" . "$A#e(B") ("f" . "$A#f(B") ("g" . "$A#g(B") ("h" . "$A#h(B") - ("i" . "$A#i(B") ("j" . "$A#j(B") ("k" . "$A#k(B") ("l" . "$A#l(B") - ("m" . "$A#m(B") ("n" . "$A#n(B") ("o" . "$A#o(B") ("p" . "$A#p(B") - ("q" . "$A#q(B") ("r" . "$A#r(B") ("s" . "$A#s(B") ("t" . "$A#t(B") - ("u" . "$A#u(B") ("v" . "$A#v(B") ("w" . "$A#w(B") ("x" . "$A#x(B") - ("y" . "$A#y(B") ("z" . "$A#z(B") - ("A" . "$A#A(B") ("B" . "$A#B(B") ("C" . "$A#C(B") ("D" . "$A#D(B") - ("E" . "$A#E(B") ("F" . "$A#F(B") ("G" . "$A#G(B") ("H" . "$A#H(B") - ("I" . "$A#I(B") ("J" . "$A#J(B") ("K" . "$A#K(B") ("L" . "$A#L(B") - ("M" . "$A#M(B") ("N" . "$A#N(B") ("O" . "$A#O(B") ("P" . "$A#P(B") - ("Q" . "$A#Q(B") ("R" . "$A#R(B") ("S" . "$A#S(B") ("T" . "$A#T(B") - ("U" . "$A#U(B") ("V" . "$A#V(B") ("W" . "$A#W(B") ("X" . "$A#X(B") - ("Y" . "$A#Y(B") ("Z" . "$A#Z(B"))) - (let ((in (car ascii)) (out (cdr ascii))) - (its-defrule (concat its-banjiao-escape in) in) - (its-defrule (concat its-quanjiao-escape in) out))) - - (its-defrule "," "$A#,(B") - (its-defrule "." "$A!#(B") - (its-defrule "/" "$A!"(B") - (its-defrule ":" "$A#:(B") - (its-defrule ";" "$A#;(B") - (its-defrule "?" "$A#?(B") - (its-defrule "!" "$A#!(B")) - -(define-its-state-machine its-erpin-tw-map - "erpin-tw" "$(GD((BC" "Chinese-CNS" - "Map for Erpin input." - - (defconst its-quanjiao-escape "Z") - (defconst its-banjiao-escape "X") - - (its-defrule-select-mode-temporally "B" downcase) - (its-defrule-select-mode-temporally "Q" quanjiao-downcase-cn) - - (its-define-erpin-table) - (its-defoutput* "b " "$(GDb(B") - (its-defoutput* "c " "$(GD_(B") - (its-defoutput* "ch " "$(GEx(B") - (its-defoutput* "d " "$(GN{(B") - (its-defoutput* "f " "$(GE0(B") - (its-defoutput* "g " "$(GT6(B") - (its-defoutput* "h " "$(GLO(B") - (its-defoutput* "i " "$(GD!(B") - (its-defoutput* "j " "$(G^s(B") - (its-defoutput* "k " "$(GF+(B") - (its-defoutput* "l " "$(GD'(B") - (its-defoutput* "m " "$(GJd(B") - (its-defoutput* "n " "$(GH!(B") - (its-defoutput* "p " "$(GJG(B") - (its-defoutput* "q " "$(GF*(B") - (its-defoutput* "r " "$(GEJ(B") - (its-defoutput* "s " "$(GQR(B") - (its-defoutput* "u " "$(GD8(B") - (its-defoutput* "t " "$(GEl(B") - (its-defoutput* "w " "$(GJ<(B") - (its-defoutput* "x " "$(GGW(B") - (its-defoutput* "y " "$(GD4(B") - (its-defoutput* "z " "$(GGc(B") - (its-defoutput* "v " "$(Gaa(B") - - (dolist (ascii '(("0" . "$(G$!(B") ("1" . "$(G$"(B") ("2" . "$(G$#(B") ("3" . "$(G$$(B") - ("4" . "$(G$%(B") ("5" . "$(G$&(B") ("6" . "$(G$'(B") ("7" . "$(G$((B") - ("8" . "$(G$)(B") ("9" . "$(G$*(B") - (" " . "$(G!!(B") ("!" . "$(G!*(B") ("@" . "$(G"i(B") ("#" . "$(G!l(B") - ("$" . "$(G"c(B") ("%" . "$(G"h(B") ("^" . "$(G!T(B") ("&" . "$(G!m(B") - ("*" . "$(G!n(B") ("(" . "$(G!>(B") (")" . "$(G!?(B") - ("-" . "$(G"1(B") ("=" . "$(G"8(B") ("`" . "$(G!j(B") ("\\" . "$(G"b(B") - ("|" . "$(G"^(B") ("_" . "$(G"%(B") ("+" . "$(G"0(B") ("~" . "$(G"D(B") - ("[" . "$(G!b(B") ("]" . "$(G!c(B") ("{" . "$A#{(B") ("}" . "$(G!a(B") - (":" . "$(G!((B") (";" . "$(G!'(B") ("\"" . "$(G!i(B") ("'" . "$(G!k(B") - ("<" . "$(G"6(B") (">" . "$(G"7(B") ("?" . "$(G!)(B") ("/" . "$(G"a(B") - ("," . "$(G!"(B") ("." . "$(G!%(B") - ("a" . "$(G$[(B") ("b" . "$(G$\(B") ("c" . "$(G$](B") ("d" . "$(G$^(B") - ("e" . "$(G$_(B") ("f" . "$(G$`(B") ("g" . "$(G$a(B") ("h" . "$(G$b(B") - ("i" . "$(G$c(B") ("j" . "$(G$d(B") ("k" . "$(G$e(B") ("l" . "$(G$f(B") - ("m" . "$(G$g(B") ("n" . "$(G$h(B") ("o" . "$(G$i(B") ("p" . "$(G$j(B") - ("q" . "$(G$k(B") ("r" . "$(G$l(B") ("s" . "$(G$m(B") ("t" . "$(G$n(B") - ("u" . "$(G$o(B") ("v" . "$(G$p(B") ("w" . "$(G$q(B") ("x" . "$(G$r(B") - ("y" . "$(G$s(B") ("z" . "$(G$t(B") - ("A" . "$(G$A(B") ("B" . "$(G$B(B") ("C" . "$(G$C(B") ("D" . "$(G$D(B") - ("E" . "$(G$E(B") ("F" . "$(G$F(B") ("G" . "$(G$G(B") ("H" . "$(G$H(B") - ("I" . "$(G$I(B") ("J" . "$(G$J(B") ("K" . "$(G$K(B") ("L" . "$(G$L(B") - ("M" . "$(G$M(B") ("N" . "$(G$N(B") ("O" . "$(G$O(B") ("P" . "$(G$P(B") - ("Q" . "$(G$Q(B") ("R" . "$(G$R(B") ("S" . "$(G$S(B") ("T" . "$(G$T(B") - ("U" . "$(G$U(B") ("V" . "$(G$V(B") ("W" . "$(G$W(B") ("X" . "$(G$X(B") - ("Y" . "$(G$Y(B") ("Z" . "$(G$Z(B"))) - (let ((in (car ascii)) (out (cdr ascii))) - (its-defrule (concat its-banjiao-escape in) in) - (its-defrule (concat its-quanjiao-escape in) out))) - - (its-defrule "," "$(G!"(B") - (its-defrule "." "$(G!$(B") - (its-defrule "/" "$(G!#(B") - (its-defrule ":" "$(G!((B") - (its-defrule ";" "$(G!'(B") - (its-defrule "?" "$(G!)(B") - (its-defrule "!" "$(G!*(B")) - -(define-its-state-machine-append its-erpin-cn-map - (its-defrule "[" its-erpin-cn-open-braket) - (its-defrule "]" its-erpin-cn-close-braket) - - (if its-erpin-cn-enable-quanjioao-alphabet - (progn - (its-defrule "1" "$A#1(B") (its-defrule "2" "$A#2(B") - (its-defrule "3" "$A#3(B") (its-defrule "4" "$A#4(B") - (its-defrule "5" "$A#5(B") (its-defrule "6" "$A#6(B") - (its-defrule "7" "$A#7(B") (its-defrule "8" "$A#8(B") - (its-defrule "9" "$A#9(B") (its-defrule "0" "$A#0(B") - (its-defrule "@" "$A#@(B") - (its-defrule "#" "$A##(B") (its-defrule "$" "$A!g(B") - (its-defrule "%" "$A#%(B") (its-defrule "^" "$A#^(B") - (its-defrule "&" "$A#&(B") (its-defrule "*" "$A#*(B") - (its-defrule "(" "$A#((B") (its-defrule ")" "$A#)(B") - (its-defrule "-" "$A#-(B") (its-defrule "~" "$A!+(B") - (its-defrule "=" "$A#=(B") (its-defrule "`" "$A#`(B") - (its-defrule "\\" "$A#\(B") (its-defrule "|" "$A#|(B") - (its-defrule "_" "$A#_(B") (its-defrule "+" "$A#+(B") - (its-defrule "{" "$A#{(B") (its-defrule "}" "$A#}(B") - (its-defrule "\"" "$A#"(B") (its-defrule "'" "$A#'(B") - (its-defrule "<" "$A#<(B") (its-defrule ">" "$A#>(B")) - (progn - (its-defrule "1" "1") (its-defrule "2" "2") - (its-defrule "3" "3") (its-defrule "4" "4") - (its-defrule "5" "5") (its-defrule "6" "6") - (its-defrule "7" "7") (its-defrule "8" "8") - (its-defrule "9" "9") (its-defrule "0" "0") - (its-defrule "@" "@") - (its-defrule "#" "#") (its-defrule "$" "$") - (its-defrule "%" "%") (its-defrule "^" "^") - (its-defrule "&" "&") (its-defrule "*" "*") - (its-defrule "(" "(") (its-defrule ")" ")") - (its-defrule "-" "-") (its-defrule "~" "~") - (its-defrule "=" "=") (its-defrule "`" "`") - (its-defrule "\\" "\\") (its-defrule "|" "|") - (its-defrule "_" "_") (its-defrule "+" "+") - (its-defrule "{" "{") (its-defrule "}" "}") - (its-defrule "\"" "\"") (its-defrule "'" "'") - (its-defrule "<" "<") (its-defrule ">" ">")))) - -(define-its-state-machine-append its-erpin-tw-map - (its-defrule "[" its-erpin-tw-open-braket) - (its-defrule "]" its-erpin-tw-close-braket) - - (if its-erpin-tw-enable-quanjioao-alphabet - (progn - (its-defrule "1" "$(G$"(B") (its-defrule "2" "$(G$#(B") - (its-defrule "3" "$(G$$(B") (its-defrule "4" "$(G$%(B") - (its-defrule "5" "$(G$&(B") (its-defrule "6" "$(G$'(B") - (its-defrule "7" "$(G$((B") (its-defrule "8" "$(G$)(B") - (its-defrule "9" "$(G$*(B") (its-defrule "0" "$(G$!(B") - (its-defrule "@" "$(G"i(B") - (its-defrule "#" "$(G!l(B") (its-defrule "$" "$(G"c(B") - (its-defrule "%" "$(G"h(B") (its-defrule "^" "$(G!T(B") - (its-defrule "&" "$(G!m(B") (its-defrule "*" "$(G!n(B") - (its-defrule "(" "$(G!>(B") (its-defrule ")" "$(G!?(B") - (its-defrule "-" "$(G"1(B") (its-defrule "~" "$(G"D(B") - (its-defrule "=" "$(G"8(B") (its-defrule "`" "$(G!j(B") - (its-defrule "\\" "$(G"b(B") (its-defrule "|" "$(G"^(B") - (its-defrule "_" "$(G"%(B") (its-defrule "+" "$(G"0(B") - (its-defrule "{" "$A#{(B") (its-defrule "}" "$(G!a(B") - (its-defrule "\"" "$(G!i(B") (its-defrule "'" "$(G!k(B") - (its-defrule "<" "$(G"6(B") (its-defrule ">" "$(G"7(B")) - (progn - (its-defrule "1" "1") (its-defrule "2" "2") - (its-defrule "3" "3") (its-defrule "4" "4") - (its-defrule "5" "5") (its-defrule "6" "6") - (its-defrule "7" "7") (its-defrule "8" "8") - (its-defrule "9" "9") (its-defrule "0" "0") - (its-defrule "@" "@") - (its-defrule "#" "#") (its-defrule "$" "$") - (its-defrule "%" "%") (its-defrule "^" "^") - (its-defrule "&" "&") (its-defrule "*" "*") - (its-defrule "(" "(") (its-defrule ")" ")") - (its-defrule "-" "-") (its-defrule "~" "~") - (its-defrule "=" "=") (its-defrule "`" "`") - (its-defrule "\\" "\\") (its-defrule "|" "|") - (its-defrule "_" "_") (its-defrule "+" "+") - (its-defrule "{" "{") (its-defrule "}" "}") - (its-defrule "\"" "\"") (its-defrule "'" "'") - (its-defrule "<" "<") (its-defrule ">" ">")))) - -(provide 'its/erpin) diff --git a/its/hankata.el b/its/hankata.el deleted file mode 100644 index fc51124..0000000 --- a/its/hankata.el +++ /dev/null @@ -1,291 +0,0 @@ -;;; its/hankata.el --- Hnakaku Katakana Input in Egg Input Method Architecture - -;; Copyright (C) 1997, 1998 Mule Project, -;; Powered by Electrotechnical Laboratory, JAPAN. -;; Project Leader: Satoru Tomura - -;; Author: Satoru Tomura - -;; This file will be part of GNU Emacs (in future). - -;; GNU Emacs is free software; you can redistribute it and/or modify -;; it under the terms of the GNU General Public License as published by -;; the Free Software Foundation; either version 2, or (at your option) -;; any later version. - -;; GNU Emacs is distributed in the hope that it will be useful, -;; but WITHOUT ANY WARRANTY; without even the implied warranty of -;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -;; GNU General Public License for more details. - -;; You should have received a copy of the GNU General Public License -;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. - -;;; Commentary: -;; -;; Symbol input is desined by jiro@math.keio.ac.jp (TANAKA Jiro) -;; This file is based on the rules of its/kata.el in Mule-2.3 distribution. -;; - -;;; Code: - -(eval-when-compile - (require 'its) - (require 'cl)) - -(defvar its-kata-enable-double-n nil "*Enable \"nn\" input for \"$B%s(B\" ") -(defvar its-kata-enable-zenkaku-alphabet t "*Enable Zenkaku alphabet") -(defvar its-kata-period "(I!(B" "*$B%T%j%*%I(B") ; ". " "$B!%(B" -(defvar its-kata-comma "(I$(B" "*$B%3%s%^(B") ; ", " "$B!$(B" -(defvar its-kata-open-bracket "(I"(B" "*[") ; "$B!N(B" -(defvar its-kata-close-bracket "(I#(B" "*]") ; "$B!O(B" -(defvar its-kata-horizontal "(I0(B" "*-") ; "$B!](B" - -(define-its-state-machine its-han-kata-map - "roma-han-kata" "(I11(B" "Japanese" nil - "Map for Romaji-Hankaku-Katakana translation. (Japanese)" - - (defconst its-hankaku-escape "~") ;; Escape character to Hankaku inputs - - (its-defrule-select-mode-temporally "q" downcase) - -;;; k k -;;; kk $B%C(Bk -;;; kka $B%C%+(B -;;; -;;; kkk $B%C(Bk DING! - - (its-defrule "tch" "(I/(B" -2) - -;;; $B!V%s!W$NF~NO(B - - (dolist (q1 '("b" "m" "p")) - (its-defrule (concat "m" q1) "(I](B" -1)) - - (its-defrule "N" "(I](B") - - (let ((state (its-goto-state "n" nil t))) - (its-make-next-state state -1 "n" "(I](B") - (its-make-next-state state ?' "n" "(I](B") - (its-defrule-otherwise state "(I](B")) - - (let ((small '"x" )) - (its-defrule (concat small "a") "(I'(B") - (its-defrule (concat small "i") "(I((B") - (its-defrule (concat small "u") "(I)(B") - (its-defrule (concat small "e") "(I*(B") - (its-defrule (concat small "o") "(I+(B") - (its-defrule (concat small "ya") "(I,(B") - (its-defrule (concat small "yu") "(I-(B") - (its-defrule (concat small "yo") "(I.(B") - (its-defrule (concat small "tu") "(I/(B") - (its-defrule (concat small "tsu") "(I/(B") - (its-defrule (concat small "wa") "(I\(B") - ) - - (its-defrule "a" "(I1(B") - (its-defrule "i" "(I2(B") - (its-defrule "u" "(I3(B") - (its-defrule "e" "(I4(B") - (its-defrule "o" "(I5(B") - - (dolist (k '(("ka" "(I6(B") ("ki" "(I7(B") ("ku" "(I8(B") ("ke" "(I9(B") ("ko" "(I:(B") - ("kya" "(I7,(B") ("kyu" "(I7-(B") ("kye" "(I7*(B") ("kyo" "(I7.(B"))) - (its-defrule (car k) (cadr k)) - (its-defrule (concat "k" (car k)) (concat "(I/(B" (cadr k)))) - (its-defoutput "kk" "(I/(Bk") - (its-defoutput "kky" "(I/(Bky") - - (dolist (s '(("sa" "(I;(B") ("si" "(I<(B") ("su" "(I=(B") ("se" "(I>(B") ("so" "(I?(B") - ("sya" "(I<,(B") ("syu" "(I<-(B") ("sye" "(I<*(B") ("syo" "(I<.(B") - ("sha" "(I<,(B") ("shi" "(I<(B") ("shu" "(I<-(B") ("she" "(I<*(B") - ("sho" "(I<.(B"))) - (its-defrule (car s) (cadr s)) - (its-defrule (concat "s" (car s)) (concat "(I/(B" (cadr s)))) - (its-defoutput "ss" "(I/(Bs") - (its-defoutput "ssy" "(I/(Bsy") - (its-defoutput "ssh" "(I/(Bsh") - - (dolist (T '(("ta" "(I@(B") ("ti" "(IA(B") ("tu" "(IB(B") ("te" "(IC(B") ("to" "(ID(B") - ("tya" "(IA,(B") ("tyi" "(IC((B") ("tyu" "(IA-(B") ("tye" "(IA*(B") - ("tyo" "(IA.(B") ("tsu" "(IB(B"))) - (its-defrule (car T) (cadr T)) - (its-defrule (concat "t" (car T)) (concat "(I/(B" (cadr T)))) - (its-defoutput "tt" "(I/(Bt") - (its-defoutput "tty" "(I/(Bty") - (its-defoutput "tts" "(I/(Bts") - - (dolist (c '(("cha" "(IA,(B") ("chi" "(IA(B") ("chu" "(IA-(B") - ("che" "(IA*(B") ("cho" "(IA.(B"))) - (its-defrule (car c) (cadr c)) - (its-defrule (concat "c" (car c)) (concat "(I/(B" (cadr c)))) - (its-defoutput "cc" "(I/(Bc") - (its-defoutput "cch" "(I/(Bch") - - (dolist (h '(("ha" "(IJ(B") ("hi" "(IK(B") ("hu" "(IL(B") ("he" "(IM(B") ("ho" "(IN(B") - ("hya" "(IK,(B") ("hyu" "(IK-(B") ("hye" "(IK*(B") ("hyo" "(IK.(B"))) - (its-defrule (car h) (cadr h)) - (its-defrule (concat "h" (car h)) (concat "(I/(B" (cadr h)))) - (its-defoutput "hh" "(I/(Bh") - (its-defoutput "hhy" "(I/(Bhy") - - (dolist (f '(("fa" "(IL'(B") ("fi" "(IL((B") ("fu" "(IL(B") ("fe" "(IL*(B") - ("fo" "(IL+(B"))) - (its-defrule (car f) (cadr f)) - (its-defrule (concat "f" (car f)) (concat "(I/(B" (cadr f)))) - (its-defoutput "ff" "(I/(Bf") - - (dolist (r '(("ra" "(IW(B") ("ri" "(IX(B") ("ru" "(IY(B") ("re" "(IZ(B") ("ro" "(I[(B") - ("rya" "(IX,(B") ("ryu" "(IX-(B") ("rye" "(IX*(B") ("ryo" "(IX.(B"))) - (its-defrule (car r) (cadr r)) - (its-defrule (concat "r" (car r)) (concat "(I/(B" (cadr r)))) - (its-defoutput "rr" "(I/(Br") - (its-defoutput "rry" "(I/(Bry") - - (dolist (l '(("la" "(IW(B") ("li" "(IX(B") ("lu" "(IY(B") ("le" "(IZ(B") ("lo" "(I[(B") - ("lya" "(IX,(B") ("lyu" "(IX-(B") ("lye" "(IX*(B") ("lyo" "(IX.(B"))) - (its-defrule (car l) (cadr l)) - (its-defrule (concat "l" (car l)) (concat "(I/(B" (cadr l)))) - (its-defoutput "ll" "(I/(Bl") - (its-defoutput "lly" "(I/(Bly") - - (dolist (g '(("ga" "(I6^(B") ("gi" "(I7^(B") ("gu" "(I8^(B") ("ge" "(I9^(B") ("go" "(I:^(B") - ("gya" "(I7^,(B") ("gyu" "(I7^-(B") ("gye" "(I7^*(B") ("gyo" "(I7^.(B"))) - (its-defrule (car g) (cadr g)) - (its-defrule (concat "g" (car g)) (concat "(I/(B" (cadr g)))) - (its-defoutput "gg" "(I/(Bg") - (its-defoutput "ggy" "(I/(Bgy") - - (dolist (z '(("za" "(I;^(B") ("zi" "(I<^(B") ("zu" "(I=^(B") ("ze" "(I>^(B") ("zo" "(I?^(B") - ("zya" "(I<^,(B") ("zyu" "(I<^-(B") ("zye" "(I<^*(B") ("zyo" "(I<^.(B"))) - (its-defrule (car z) (cadr z)) - (its-defrule (concat "z" (car z)) (concat "(I/(B" (cadr z)))) - (its-defoutput "zz" "(I/(Bz") - (its-defoutput "zzy" "(I/(Bzy") - - (dolist (j '(("ja" "(I<^,(B") ("ji" "(I<^(B") ("ju" "(I<^-(B") ("je" "(I<^*(B") - ("jo" "(I<^.(B") ("jya" "(I<^,(B") ("jyu" "(I<^-(B") ("jye" "(I<^*(B") - ("jyo" "(I<^.(B"))) - (its-defrule (car j) (cadr j)) - (its-defrule (concat "j" (car j)) (concat "(I/(B" (cadr j)))) - (its-defoutput "jj" "(I/(Bj") - (its-defoutput "jjy" "(I/(Bjy") - - (dolist (d '(("da" "(I@^(B") ("di" "(IA^(B") ("du" "(IB^(B") ("de" "(IC^(B") ("do" "(ID^(B") - ("dya" "(IA^,(B") ("dyi" "(IC^((B") ("dyu" "(IA^-(B") ("dye" "(IA^*(B") - ("dyo" "(IA^.(B"))) - (its-defrule (car d) (cadr d)) - (its-defrule (concat "d" (car d)) (concat "(I/(B" (cadr d)))) - (its-defoutput "dd" "(I/(Bd") - (its-defoutput "ddy" "(I/(Bdy") - - (dolist (b '(("ba" "(IJ^(B") ("bi" "(IK^(B") ("bu" "(IL^(B") ("be" "(IM^(B") ("bo" "(IN^(B") - ("bya" "(IK^,(B") ("byu" "(IK^-(B") ("bye" "(IK^*(B") ("byo" "(IK^.(B"))) - (its-defrule (car b) (cadr b)) - (its-defrule (concat "b" (car b)) (concat "(I/(B" (cadr b)))) - (its-defoutput "bb" "(I/(Bb") - (its-defoutput "bby" "(I/(Bby") - - (dolist (p '(("pa" "(IJ_(B") ("pi" "(IK_(B") ("pu" "(IL_(B") ("pe" "(IM_(B") ("po" "(IN_(B") - ("pya" "(IK_,(B") ("pyu" "(IK_-(B") ("pye" "(IK_*(B") ("pyo" "(IK_.(B"))) - (its-defrule (car p) (cadr p)) - (its-defrule (concat "p" (car p)) (concat "(I/(B" (cadr p)))) - (its-defoutput "pp" "(I/(Bp") - (its-defoutput "ppy" "(I/(Bpy") - - (dolist (v '(("va" "(I3^'(B") ("vi" "(I3^((B") ("vu" "(I3^(B") ("ve" "(I3^*(B") - ("vo" "(I3^+(B"))) - (its-defrule (car v) (cadr v)) - (its-defrule (concat "v" (car v)) (concat "(I/(B" (cadr v)))) - (its-defoutput "vv" "(I/(Bv") - - (its-defrule "ma" "(IO(B") - (its-defrule "mi" "(IP(B") - (its-defrule "mu" "(IQ(B") - (its-defrule "me" "(IR(B") - (its-defrule "mo" "(IS(B") - (its-defrule "mya" "(IP,(B") - (its-defrule "myu" "(IP-(B") - (its-defrule "mye" "(IP*(B") - (its-defrule "myo" "(IP.(B") - (its-defrule "ya" "(IT(B") - (its-defrule "yi" "(I2(B") - (its-defrule "yu" "(IU(B") - (its-defrule "yo" "(IV(B") - (its-defrule "ye" "(I2*(B") - (its-defrule "wa" "(I\(B") - (its-defrule "wi" "(I((B") - (its-defrule "wu" "(I3(B") - (its-defrule "we" "(I*(B") - (its-defrule "wo" "(I&(B") - - (its-defrule "kwa" "(I8\(B") - (its-defrule "kwi" "(I8((B") - (its-defrule "kwu" "(I8(B") - (its-defrule "kwe" "(I8*(B") - (its-defrule "kwo" "(I8+(B") - (its-defrule "gwa" "(I8^\(B") - (its-defrule "gwi" "(I8^((B") - (its-defrule "gwu" "(I8^(B") - (its-defrule "gwe" "(I8^*(B") - (its-defrule "gwo" "(I8^+(B") - (its-defrule "tsa" "(IB'(B") - (its-defrule "tsi" "(IB((B") - (its-defrule "tse" "(IB*(B") - (its-defrule "tso" "(IB+(B") - - (its-defrule "na" "(IE(B") - (its-defrule "ni" "(IF(B") - (its-defrule "nu" "(IG(B") - (its-defrule "ne" "(IH(B") - (its-defrule "no" "(II(B") - (its-defrule "nya" "(IF,(B") - (its-defrule "nyu" "(IF-(B") - (its-defrule "nye" "(IF*(B") - (its-defrule "nyo" "(IF.(B") - - (its-defrule "xti" "(IC((B") - (its-defrule "xdi" "(IC^((B") - (its-defrule "xdu" "(ID^)(B") - (its-defrule "xde" "(IC^*(B") - (its-defrule "xdo" "(ID^+(B") - (its-defrule "xwi" "(I3((B") - (its-defrule "xwe" "(I3*(B") - (its-defrule "xwo" "(I3+(B") - -;;; -;;; Symbol inputs -;;; - - (dolist (digit '( "1" "2" "3" "4" "5" "6" "7" "8" "9" "0" )) - (its-defrule (concat its-hankaku-escape digit) digit)) - - (dolist (symbol '( " " "!" "@" "#" "$" "%" "^" "&" "*" "(" ")" - "-" "=" "`" "\\" "|" "_" "+" "~" "[" "]" "{" "}" - ":" ";" "\"" "'" "<" ">" "?" "/" "," "." )) - (its-defrule (concat its-hankaku-escape symbol) symbol)) - - (dolist (downcase '("a" "b" "c" "d" "e" "f" "g" "h" "i" "j" "k" "l" "m" "n" - "o" "p" "q" "r" "s" "t" "u" "v" "w" "x" "y" "z")) - (its-defrule (concat its-hankaku-escape downcase) downcase)) - - (dolist (upcase '("A" "B" "C" "D" "E" "F" "G" "H" "I" "J" "K" "L" "M" "N" - "O" "P" "Q" "R" "S" "T" "U" "V" "W" "X" "Y" "Z")) - (its-defrule (concat its-hankaku-escape upcase) upcase))) - -(define-its-state-machine-append its-han-kata-map - (if its-kata-enable-double-n - (its-defrule "nn" "(I](B") - (its-defrule "nn" "(I](B" -1)) - - (its-defrule "-" its-kata-horizontal) - (its-defrule "[" its-kata-open-bracket) - (its-defrule "]" its-kata-close-bracket) - (its-defrule "." its-kata-period) - (its-defrule "," its-kata-comma) - ) - -(provide 'its/hankata) -;;; its/kata.el ends here. diff --git a/its/jeonkak.el b/its/jeonkak.el deleted file mode 100644 index 2baedfe..0000000 --- a/its/jeonkak.el +++ /dev/null @@ -1,103 +0,0 @@ -;;; its/jeonkak.el --- Jeonkak ASCII Input in Egg Input Method Architecture - -;; Copyright (C) 1997, 1998 Mule Project, -;; Powered by Electrotechnical Laboratory, JAPAN. -;; Project Leader: Satoru Tomura - -;; Author: KATAYAMA Yoshio - -;; This file will be part of GNU Emacs (in future). - -;; GNU Emacs is free software; you can redistribute it and/or modify -;; it under the terms of the GNU General Public License as published by -;; the Free Software Foundation; either version 2, or (at your option) -;; any later version. - -;; GNU Emacs is distributed in the hope that it will be useful, -;; but WITHOUT ANY WARRANTY; without even the implied warranty of -;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -;; GNU General Public License for more details. - -;; You should have received a copy of the GNU General Public License -;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. - -;;; Commentary: -;; -;; Symbol input is desined by jiro@math.keio.ac.jp (TANAKA Jiro) -;; This file is based on the rules of its/hira.el in Mule-2.3 distribution. -;; - -;;; Code: - -(eval-when-compile - (require 'its)) - -(define-its-state-machine its-jeonkak-up-map - "jeonkak-upcase" "$(C#A(B" "Korean" nil - "Map for jeonkak-upcase input." - - (dolist (ascii '(("1" . "$(C#1(B") ("2" . "$(C#2(B") ("3" . "$(C#3(B") ("4" . "$(C#4(B") - ("5" . "$(C#5(B") ("6" . "$(C#6(B") ("7" . "$(C#7(B") ("8" . "$(C#8(B") - ("9" . "$(C#9(B") ("0" . "$(C#0(B") - (" " . "$(C!!(B") ("!" . "$(C#!(B") ("@" . "$(C#@(B") ("#" . "$(C##(B") - ("$" . "$(C#$(B") ("%" . "$(C#%(B") ("^" . "$(C#^(B") ("&" . "$(C#&(B") - ("*" . "$(C#*(B") ("(" . "$(C#((B") (")" . "$(C#)(B") - ("-" . "$(C#-(B") ("=" . "$(C#=(B") ("`" . "$(C#`(B") ("\\" . "$(C#\(B") - ("|" . "$(C#|(B") ("_" . "$(C#_(B") ("+" . "$(C#+(B") ("~" . "$(C#~(B") - ("[" . "$(C!8(B") ("]" . "$(C!9(B") ("{" . "$(C#{(B") ("}" . "$(C#}(B") - (":" . "$(C#:(B") (";" . "$(C#;(B") ("\"" . "$(C#"(B") ("'" . "$(C#'(B") - ("<" . "$(C#<(B") (">" . "$(C#>(B") ("?" . "$(C#?(B") ("/" . "$(C#/(B") - ("," . "$(C#,(B") ("." . "$(C#.(B") - ("a" . "$(C#A(B") ("b" . "$(C#B(B") ("c" . "$(C#C(B") ("d" . "$(C#D(B") - ("e" . "$(C#E(B") ("f" . "$(C#F(B") ("g" . "$(C#G(B") ("h" . "$(C#H(B") - ("i" . "$(C#I(B") ("j" . "$(C#J(B") ("k" . "$(C#K(B") ("l" . "$(C#L(B") - ("m" . "$(C#M(B") ("n" . "$(C#N(B") ("o" . "$(C#O(B") ("p" . "$(C#P(B") - ("q" . "$(C#Q(B") ("r" . "$(C#R(B") ("s" . "$(C#S(B") ("t" . "$(C#T(B") - ("u" . "$(C#U(B") ("v" . "$(C#V(B") ("w" . "$(C#W(B") ("x" . "$(C#X(B") - ("y" . "$(C#Y(B") ("z" . "$(C#Z(B") - ("A" . "$(C#A(B") ("B" . "$(C#B(B") ("C" . "$(C#C(B") ("D" . "$(C#D(B") - ("E" . "$(C#E(B") ("F" . "$(C#F(B") ("G" . "$(C#G(B") ("H" . "$(C#H(B") - ("I" . "$(C#I(B") ("J" . "$(C#J(B") ("K" . "$(C#K(B") ("L" . "$(C#L(B") - ("M" . "$(C#M(B") ("N" . "$(C#N(B") ("O" . "$(C#O(B") ("P" . "$(C#P(B") - ("Q" . "$(C#Q(B") ("R" . "$(C#R(B") ("S" . "$(C#S(B") ("T" . "$(C#T(B") - ("U" . "$(C#U(B") ("V" . "$(C#V(B") ("W" . "$(C#W(B") ("X" . "$(C#X(B") - ("Y" . "$(C#Y(B") ("Z" . "$(C#Z(B"))) - (let ((in (car ascii)) (out (cdr ascii))) - (its-defrule in out)))) - -(define-its-state-machine its-jeonkak-down-map - "jeonkak-downcase" "$(C#a(B" "Korean" nil - "Map for jeonkak-downcase input." - - (dolist (ascii '(("1" . "$(C#1(B") ("2" . "$(C#2(B") ("3" . "$(C#3(B") ("4" . "$(C#4(B") - ("5" . "$(C#5(B") ("6" . "$(C#6(B") ("7" . "$(C#7(B") ("8" . "$(C#8(B") - ("9" . "$(C#9(B") ("0" . "$(C#0(B") - (" " . "$(C!!(B") ("!" . "$(C#!(B") ("@" . "$(C#@(B") ("#" . "$(C##(B") - ("$" . "$(C#$(B") ("%" . "$(C#%(B") ("^" . "$(C#^(B") ("&" . "$(C#&(B") - ("*" . "$(C#*(B") ("(" . "$(C#((B") (")" . "$(C#)(B") - ("-" . "$(C#-(B") ("=" . "$(C#=(B") ("`" . "$(C#`(B") ("\\" . "$(C#\(B") - ("|" . "$(C#|(B") ("_" . "$(C#_(B") ("+" . "$(C#+(B") ("~" . "$(C#~(B") - ("[" . "$(C!8(B") ("]" . "$(C!9(B") ("{" . "$(C#{(B") ("}" . "$(C#}(B") - (":" . "$(C#:(B") (";" . "$(C#;(B") ("\"" . "$(C#"(B") ("'" . "$(C#'(B") - ("<" . "$(C#<(B") (">" . "$(C#>(B") ("?" . "$(C#?(B") ("/" . "$(C#/(B") - ("," . "$(C#,(B") ("." . "$(C#.(B") - ("a" . "$(C#a(B") ("b" . "$(C#b(B") ("c" . "$(C#c(B") ("d" . "$(C#d(B") - ("e" . "$(C#e(B") ("f" . "$(C#f(B") ("g" . "$(C#g(B") ("h" . "$(C#h(B") - ("i" . "$(C#i(B") ("j" . "$(C#j(B") ("k" . "$(C#k(B") ("l" . "$(C#l(B") - ("m" . "$(C#m(B") ("n" . "$(C#n(B") ("o" . "$(C#o(B") ("p" . "$(C#p(B") - ("q" . "$(C#q(B") ("r" . "$(C#r(B") ("s" . "$(C#s(B") ("t" . "$(C#t(B") - ("u" . "$(C#u(B") ("v" . "$(C#v(B") ("w" . "$(C#w(B") ("x" . "$(C#x(B") - ("y" . "$(C#y(B") ("z" . "$(C#z(B") - ("A" . "$(C#A(B") ("B" . "$(C#B(B") ("C" . "$(C#C(B") ("D" . "$(C#D(B") - ("E" . "$(C#E(B") ("F" . "$(C#F(B") ("G" . "$(C#G(B") ("H" . "$(C#H(B") - ("I" . "$(C#I(B") ("J" . "$(C#J(B") ("K" . "$(C#K(B") ("L" . "$(C#L(B") - ("M" . "$(C#M(B") ("N" . "$(C#N(B") ("O" . "$(C#O(B") ("P" . "$(C#P(B") - ("Q" . "$(C#Q(B") ("R" . "$(C#R(B") ("S" . "$(C#S(B") ("T" . "$(C#T(B") - ("U" . "$(C#U(B") ("V" . "$(C#V(B") ("W" . "$(C#W(B") ("X" . "$(C#X(B") - ("Y" . "$(C#Y(B") ("Z" . "$(C#Z(B"))) - (let ((in (car ascii)) (out (cdr ascii))) - (its-defrule in out)))) - -(provide 'its/jeonkak) diff --git a/its/kata.el b/its/kata.el deleted file mode 100644 index b138b66..0000000 --- a/its/kata.el +++ /dev/null @@ -1,489 +0,0 @@ -;;; its/kata.el --- Katakana Input in Egg Input Method Architecture - -;; Copyright (C) 1997, 1998 Mule Project, -;; Powered by Electrotechnical Laboratory, JAPAN. -;; Project Leader: Satoru Tomura - -;; Author: Satoru Tomura -;; jiro@math.keio.ac.jp (TANAKA Jiro) - -;; This file will be part of GNU Emacs (in future). - -;; GNU Emacs is free software; you can redistribute it and/or modify -;; it under the terms of the GNU General Public License as published by -;; the Free Software Foundation; either version 2, or (at your option) -;; any later version. - -;; GNU Emacs is distributed in the hope that it will be useful, -;; but WITHOUT ANY WARRANTY; without even the implied warranty of -;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -;; GNU General Public License for more details. - -;; You should have received a copy of the GNU General Public License -;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. - -;;; Commentary: -;; -;; Symbol input is desined by jiro@math.keio.ac.jp (TANAKA Jiro) -;; This file is based on the rules of its/kata.el in Mule-2.3 distribution. -;; - -;;; Code: - -(eval-when-compile - (require 'its) - (require 'cl)) - -(defvar its-kata-enable-double-n nil "*Enable \"nn\" input for \"$B%s(B\" ") -(defvar its-kata-enable-zenkaku-alphabet t "*Enable Zenkaku alphabet") -(defvar its-kata-period "$B!#(B" "*$B%T%j%*%I(B") ; ". " "$B!%(B" -(defvar its-kata-comma "$B!"(B" "*$B%3%s%^(B") ; ", " "$B!$(B" -(defvar its-kata-open-bracket "$B!V(B" "*[") ; "$B!N(B" -(defvar its-kata-close-bracket "$B!W(B" "*]") ; "$B!O(B" -(defvar its-kata-horizontal "$B!<(B" "*-") ; "$B!](B" - -(define-its-state-machine its-kata-map - "roma-kata" "$B%"(B" "Japanese" nil - "Map for Romaji-Katakana translation. (Japanese)" - - (defconst its-zenkaku-escape "Z") ;; Escape character to Zenkaku inputs - (defconst its-hankaku-escape "~") ;; Escape character to Hankaku inputs - - (its-defrule-select-mode-temporally "q" downcase) - (its-defrule-select-mode-temporally "Q" zenkaku-downcase) - -;;; k k -;;; kk $B%C(Bk -;;; kka $B%C%+(B -;;; -;;; kkk $B%C(Bk DING! - - (its-defrule "tch" "$B%C(B" -2) - -;;; $B!V%s!W$NF~NO(B - - (dolist (q1 '("b" "m" "p")) - (its-defrule (concat "m" q1) "$B%s(B" -1)) - - (its-defrule "N" "$B%s(B") - - (let ((state (its-goto-state "n" nil t))) - (its-make-next-state state -1 "n" "$B%s(B") - (its-make-next-state state ?' "n" "$B%s(B") - (its-defrule-otherwise state "$B%s(B")) - - (let ((small '"x" )) - (its-defrule (concat small "a") "$B%!(B") - (its-defrule (concat small "i") "$B%#(B") - (its-defrule (concat small "u") "$B%%(B") - (its-defrule (concat small "e") "$B%'(B") - (its-defrule (concat small "o") "$B%)(B") - (its-defrule (concat small "ya") "$B%c(B") - (its-defrule (concat small "yu") "$B%e(B") - (its-defrule (concat small "yo") "$B%g(B") - (its-defrule (concat small "tu") "$B%C(B") - (its-defrule (concat small "tsu") "$B%C(B") - (its-defrule (concat small "wa") "$B%n(B") - ) - - (its-defrule "a" "$B%"(B") - (its-defrule "i" "$B%$(B") - (its-defrule "u" "$B%&(B") - (its-defrule "e" "$B%((B") - (its-defrule "o" "$B%*(B") - - (dolist (k '(("ka" "$B%+(B") ("ki" "$B%-(B") ("ku" "$B%/(B") ("ke" "$B%1(B") ("ko" "$B%3(B") - ("kya" "$B%-%c(B") ("kyu" "$B%-%e(B") ("kye" "$B%-%'(B") ("kyo" "$B%-%g(B"))) - (its-defrule (car k) (cadr k)) - (its-defrule (concat "k" (car k)) (concat "$B%C(B" (cadr k)))) - (its-defoutput "kk" "$B%C(Bk") - (its-defoutput "kky" "$B%C(Bky") - - (dolist (s '(("sa" "$B%5(B") ("si" "$B%7(B") ("su" "$B%9(B") ("se" "$B%;(B") ("so" "$B%=(B") - ("sya" "$B%7%c(B") ("syu" "$B%7%e(B") ("sye" "$B%7%'(B") ("syo" "$B%7%g(B") - ("sha" "$B%7%c(B") ("shi" "$B%7(B") ("shu" "$B%7%e(B") ("she" "$B%7%'(B") - ("sho" "$B%7%g(B"))) - (its-defrule (car s) (cadr s)) - (its-defrule (concat "s" (car s)) (concat "$B%C(B" (cadr s)))) - (its-defoutput "ss" "$B%C(Bs") - (its-defoutput "ssy" "$B%C(Bsy") - (its-defoutput "ssh" "$B%C(Bsh") - - (dolist (T '(("ta" "$B%?(B") ("ti" "$B%A(B") ("tu" "$B%D(B") ("te" "$B%F(B") ("to" "$B%H(B") - ("tya" "$B%A%c(B") ("tyi" "$B%F%#(B") ("tyu" "$B%A%e(B") ("tye" "$B%A%'(B") - ("tyo" "$B%A%g(B") ("tsu" "$B%D(B"))) - (its-defrule (car T) (cadr T)) - (its-defrule (concat "t" (car T)) (concat "$B%C(B" (cadr T)))) - (its-defoutput "tt" "$B%C(Bt") - (its-defoutput "tty" "$B%C(Bty") - (its-defoutput "tts" "$B%C(Bts") - - (dolist (c '(("cha" "$B%A%c(B") ("chi" "$B%A(B") ("chu" "$B%A%e(B") - ("che" "$B%A%'(B") ("cho" "$B%A%g(B"))) - (its-defrule (car c) (cadr c)) - (its-defrule (concat "c" (car c)) (concat "$B%C(B" (cadr c)))) - (its-defoutput "cc" "$B%C(Bc") - (its-defoutput "cch" "$B%C(Bch") - - (dolist (h '(("ha" "$B%O(B") ("hi" "$B%R(B") ("hu" "$B%U(B") ("he" "$B%X(B") ("ho" "$B%[(B") - ("hya" "$B%R%c(B") ("hyu" "$B%R%e(B") ("hye" "$B%R%'(B") ("hyo" "$B%R%g(B"))) - (its-defrule (car h) (cadr h)) - (its-defrule (concat "h" (car h)) (concat "$B%C(B" (cadr h)))) - (its-defoutput "hh" "$B%C(Bh") - (its-defoutput "hhy" "$B%C(Bhy") - - (dolist (f '(("fa" "$B%U%!(B") ("fi" "$B%U%#(B") ("fu" "$B%U(B") ("fe" "$B%U%'(B") - ("fo" "$B%U%)(B"))) - (its-defrule (car f) (cadr f)) - (its-defrule (concat "f" (car f)) (concat "$B%C(B" (cadr f)))) - (its-defoutput "ff" "$B%C(Bf") - - (dolist (r '(("ra" "$B%i(B") ("ri" "$B%j(B") ("ru" "$B%k(B") ("re" "$B%l(B") ("ro" "$B%m(B") - ("rya" "$B%j%c(B") ("ryu" "$B%j%e(B") ("rye" "$B%j%'(B") ("ryo" "$B%j%g(B"))) - (its-defrule (car r) (cadr r)) - (its-defrule (concat "r" (car r)) (concat "$B%C(B" (cadr r)))) - (its-defoutput "rr" "$B%C(Br") - (its-defoutput "rry" "$B%C(Bry") - - (dolist (l '(("la" "$B%i(B") ("li" "$B%j(B") ("lu" "$B%k(B") ("le" "$B%l(B") ("lo" "$B%m(B") - ("lya" "$B%j%c(B") ("lyu" "$B%j%e(B") ("lye" "$B%j%'(B") ("lyo" "$B%j%g(B"))) - (its-defrule (car l) (cadr l)) - (its-defrule (concat "l" (car l)) (concat "$B%C(B" (cadr l)))) - (its-defoutput "ll" "$B%C(Bl") - (its-defoutput "lly" "$B%C(Bly") - - (dolist (g '(("ga" "$B%,(B") ("gi" "$B%.(B") ("gu" "$B%0(B") ("ge" "$B%2(B") ("go" "$B%4(B") - ("gya" "$B%.%c(B") ("gyu" "$B%.%e(B") ("gye" "$B%.%'(B") ("gyo" "$B%.%g(B"))) - (its-defrule (car g) (cadr g)) - (its-defrule (concat "g" (car g)) (concat "$B%C(B" (cadr g)))) - (its-defoutput "gg" "$B%C(Bg") - (its-defoutput "ggy" "$B%C(Bgy") - - (dolist (z '(("za" "$B%6(B") ("zi" "$B%8(B") ("zu" "$B%:(B") ("ze" "$B%<(B") ("zo" "$B%>(B") - ("zya" "$B%8%c(B") ("zyu" "$B%8%e(B") ("zye" "$B%8%'(B") ("zyo" "$B%8%g(B"))) - (its-defrule (car z) (cadr z)) - (its-defrule (concat "z" (car z)) (concat "$B%C(B" (cadr z)))) - (its-defoutput "zz" "$B%C(Bz") - (its-defoutput "zzy" "$B%C(Bzy") - - (dolist (j '(("ja" "$B%8%c(B") ("ji" "$B%8(B") ("ju" "$B%8%e(B") ("je" "$B%8%'(B") - ("jo" "$B%8%g(B") ("jya" "$B%8%c(B") ("jyu" "$B%8%e(B") ("jye" "$B%8%'(B") - ("jyo" "$B%8%g(B"))) - (its-defrule (car j) (cadr j)) - (its-defrule (concat "j" (car j)) (concat "$B%C(B" (cadr j)))) - (its-defoutput "jj" "$B%C(Bj") - (its-defoutput "jjy" "$B%C(Bjy") - - (dolist (d '(("da" "$B%@(B") ("di" "$B%B(B") ("du" "$B%E(B") ("de" "$B%G(B") ("do" "$B%I(B") - ("dya" "$B%B%c(B") ("dyi" "$B%G%#(B") ("dyu" "$B%B%e(B") ("dye" "$B%B%'(B") - ("dyo" "$B%B%g(B"))) - (its-defrule (car d) (cadr d)) - (its-defrule (concat "d" (car d)) (concat "$B%C(B" (cadr d)))) - (its-defoutput "dd" "$B%C(Bd") - (its-defoutput "ddy" "$B%C(Bdy") - - (dolist (b '(("ba" "$B%P(B") ("bi" "$B%S(B") ("bu" "$B%V(B") ("be" "$B%Y(B") ("bo" "$B%\(B") - ("bya" "$B%S%c(B") ("byu" "$B%S%e(B") ("bye" "$B%S%'(B") ("byo" "$B%S%g(B"))) - (its-defrule (car b) (cadr b)) - (its-defrule (concat "b" (car b)) (concat "$B%C(B" (cadr b)))) - (its-defoutput "bb" "$B%C(Bb") - (its-defoutput "bby" "$B%C(Bby") - - (dolist (p '(("pa" "$B%Q(B") ("pi" "$B%T(B") ("pu" "$B%W(B") ("pe" "$B%Z(B") ("po" "$B%](B") - ("pya" "$B%T%c(B") ("pyu" "$B%T%e(B") ("pye" "$B%T%'(B") ("pyo" "$B%T%g(B"))) - (its-defrule (car p) (cadr p)) - (its-defrule (concat "p" (car p)) (concat "$B%C(B" (cadr p)))) - (its-defoutput "pp" "$B%C(Bp") - (its-defoutput "ppy" "$B%C(Bpy") - - (dolist (v '(("va" "$B%t%!(B") ("vi" "$B%t%#(B") ("vu" "$B%t(B") ("ve" "$B%t%'(B") - ("vo" "$B%t%)(B"))) - (its-defrule (car v) (cadr v)) - (its-defrule (concat "v" (car v)) (concat "$B%C(B" (cadr v)))) - (its-defoutput "vv" "$B%C(Bv") - - (its-defrule "ma" "$B%^(B") - (its-defrule "mi" "$B%_(B") - (its-defrule "mu" "$B%`(B") - (its-defrule "me" "$B%a(B") - (its-defrule "mo" "$B%b(B") - (its-defrule "mya" "$B%_%c(B") - (its-defrule "myu" "$B%_%e(B") - (its-defrule "mye" "$B%_%'(B") - (its-defrule "myo" "$B%_%g(B") - (its-defrule "ya" "$B%d(B") - (its-defrule "yi" "$B%$(B") - (its-defrule "yu" "$B%f(B") - (its-defrule "yo" "$B%h(B") - (its-defrule "ye" "$B%$%'(B") - (its-defrule "wa" "$B%o(B") - (its-defrule "wi" "$B%p(B") - (its-defrule "wu" "$B%&(B") - (its-defrule "we" "$B%q(B") - (its-defrule "wo" "$B%r(B") - - (its-defrule "kwa" "$B%/%n(B") - (its-defrule "kwi" "$B%/%#(B") - (its-defrule "kwu" "$B%/(B") - (its-defrule "kwe" "$B%/%'(B") - (its-defrule "kwo" "$B%/%)(B") - (its-defrule "gwa" "$B%0%n(B") - (its-defrule "gwi" "$B%0%#(B") - (its-defrule "gwu" "$B%0(B") - (its-defrule "gwe" "$B%0%'(B") - (its-defrule "gwo" "$B%0%)(B") - (its-defrule "tsa" "$B%D%!(B") - (its-defrule "tsi" "$B%D%#(B") - (its-defrule "tse" "$B%D%'(B") - (its-defrule "tso" "$B%D%)(B") - - (its-defrule "na" "$B%J(B") - (its-defrule "ni" "$B%K(B") - (its-defrule "nu" "$B%L(B") - (its-defrule "ne" "$B%M(B") - (its-defrule "no" "$B%N(B") - (its-defrule "nya" "$B%K%c(B") - (its-defrule "nyu" "$B%K%e(B") - (its-defrule "nye" "$B%K%'(B") - (its-defrule "nyo" "$B%K%g(B") - - (its-defrule "xka" "$B%u(B") - (its-defrule "xke" "$B%v(B") - (its-defrule "xti" "$B%F%#(B") - (its-defrule "xdi" "$B%G%#(B") - (its-defrule "xdu" "$B%I%%(B") - (its-defrule "xde" "$B%G%'(B") - (its-defrule "xdo" "$B%I%)(B") - (its-defrule "xwi" "$B%&%#(B") - (its-defrule "xwe" "$B%&%'(B") - (its-defrule "xwo" "$B%&%)(B") - -;;; -;;; Zenkaku inputs -;;; - - (its-defrule (concat its-zenkaku-escape "0") "$B#0(B") - (its-defrule (concat its-zenkaku-escape "1") "$B#1(B") - (its-defrule (concat its-zenkaku-escape "2") "$B#2(B") - (its-defrule (concat its-zenkaku-escape "3") "$B#3(B") - (its-defrule (concat its-zenkaku-escape "4") "$B#4(B") - (its-defrule (concat its-zenkaku-escape "5") "$B#5(B") - (its-defrule (concat its-zenkaku-escape "6") "$B#6(B") - (its-defrule (concat its-zenkaku-escape "7") "$B#7(B") - (its-defrule (concat its-zenkaku-escape "8") "$B#8(B") - (its-defrule (concat its-zenkaku-escape "9") "$B#9(B") - - (its-defrule (concat its-zenkaku-escape "A") "$B#A(B") - (its-defrule (concat its-zenkaku-escape "B") "$B#B(B") - (its-defrule (concat its-zenkaku-escape "C") "$B#C(B") - (its-defrule (concat its-zenkaku-escape "D") "$B#D(B") - (its-defrule (concat its-zenkaku-escape "E") "$B#E(B") - (its-defrule (concat its-zenkaku-escape "F") "$B#F(B") - (its-defrule (concat its-zenkaku-escape "G") "$B#G(B") - (its-defrule (concat its-zenkaku-escape "H") "$B#H(B") - (its-defrule (concat its-zenkaku-escape "I") "$B#I(B") - (its-defrule (concat its-zenkaku-escape "J") "$B#J(B") - (its-defrule (concat its-zenkaku-escape "K") "$B#K(B") - (its-defrule (concat its-zenkaku-escape "L") "$B#L(B") - (its-defrule (concat its-zenkaku-escape "M") "$B#M(B") - (its-defrule (concat its-zenkaku-escape "N") "$B#N(B") - (its-defrule (concat its-zenkaku-escape "O") "$B#O(B") - (its-defrule (concat its-zenkaku-escape "P") "$B#P(B") - (its-defrule (concat its-zenkaku-escape "Q") "$B#Q(B") - (its-defrule (concat its-zenkaku-escape "R") "$B#R(B") - (its-defrule (concat its-zenkaku-escape "S") "$B#S(B") - (its-defrule (concat its-zenkaku-escape "T") "$B#T(B") - (its-defrule (concat its-zenkaku-escape "U") "$B#U(B") - (its-defrule (concat its-zenkaku-escape "V") "$B#V(B") - (its-defrule (concat its-zenkaku-escape "W") "$B#W(B") - (its-defrule (concat its-zenkaku-escape "X") "$B#X(B") - (its-defrule (concat its-zenkaku-escape "Y") "$B#Y(B") - (its-defrule (concat its-zenkaku-escape "Z") "$B#Z(B") - - (its-defrule (concat its-zenkaku-escape "a") "$B#a(B") - (its-defrule (concat its-zenkaku-escape "b") "$B#b(B") - (its-defrule (concat its-zenkaku-escape "c") "$B#c(B") - (its-defrule (concat its-zenkaku-escape "d") "$B#d(B") - (its-defrule (concat its-zenkaku-escape "e") "$B#e(B") - (its-defrule (concat its-zenkaku-escape "f") "$B#f(B") - (its-defrule (concat its-zenkaku-escape "g") "$B#g(B") - (its-defrule (concat its-zenkaku-escape "h") "$B#h(B") - (its-defrule (concat its-zenkaku-escape "i") "$B#i(B") - (its-defrule (concat its-zenkaku-escape "j") "$B#j(B") - (its-defrule (concat its-zenkaku-escape "k") "$B#k(B") - (its-defrule (concat its-zenkaku-escape "l") "$B#l(B") - (its-defrule (concat its-zenkaku-escape "m") "$B#m(B") - (its-defrule (concat its-zenkaku-escape "n") "$B#n(B") - (its-defrule (concat its-zenkaku-escape "o") "$B#o(B") - (its-defrule (concat its-zenkaku-escape "p") "$B#p(B") - (its-defrule (concat its-zenkaku-escape "q") "$B#q(B") - (its-defrule (concat its-zenkaku-escape "r") "$B#r(B") - (its-defrule (concat its-zenkaku-escape "s") "$B#s(B") - (its-defrule (concat its-zenkaku-escape "t") "$B#t(B") - (its-defrule (concat its-zenkaku-escape "u") "$B#u(B") - (its-defrule (concat its-zenkaku-escape "v") "$B#v(B") - (its-defrule (concat its-zenkaku-escape "w") "$B#w(B") - (its-defrule (concat its-zenkaku-escape "x") "$B#x(B") - (its-defrule (concat its-zenkaku-escape "y") "$B#y(B") - (its-defrule (concat its-zenkaku-escape "z") "$B#z(B") - - (its-defrule (concat its-zenkaku-escape " ") "$B!!(B") - (its-defrule (concat its-zenkaku-escape "!") "$B!*(B") - (its-defrule (concat its-zenkaku-escape "@") "$B!w(B") - (its-defrule (concat its-zenkaku-escape "#") "$B!t(B") - (its-defrule (concat its-zenkaku-escape "$") "$B!p(B") - (its-defrule (concat its-zenkaku-escape "%") "$B!s(B") - (its-defrule (concat its-zenkaku-escape "^") "$B!0(B") - (its-defrule (concat its-zenkaku-escape "&") "$B!u(B") - (its-defrule (concat its-zenkaku-escape "*") "$B!v(B") - (its-defrule (concat its-zenkaku-escape "(") "$B!J(B") - (its-defrule (concat its-zenkaku-escape ")") "$B!K(B") - (its-defrule (concat its-zenkaku-escape "-") "$B!](B") - (its-defrule (concat its-zenkaku-escape "=") "$B!a(B") - (its-defrule (concat its-zenkaku-escape "`") "$B!.(B") - (its-defrule (concat its-zenkaku-escape "\\") "$B!o(B") - (its-defrule (concat its-zenkaku-escape "|") "$B!C(B") - (its-defrule (concat its-zenkaku-escape "_") "$B!2(B") - (its-defrule (concat its-zenkaku-escape "+") "$B!\(B") - (its-defrule (concat its-zenkaku-escape "~") "$B!1(B") - (its-defrule (concat its-zenkaku-escape "[") "$B!N(B") - (its-defrule (concat its-zenkaku-escape "]") "$B!O(B") - (its-defrule (concat its-zenkaku-escape "{") "$B!P(B") - (its-defrule (concat its-zenkaku-escape "}") "$B!Q(B") - (its-defrule (concat its-zenkaku-escape ":") "$B!'(B") - (its-defrule (concat its-zenkaku-escape ";") "$B!((B") - (its-defrule (concat its-zenkaku-escape "\"") "$B!I(B") - (its-defrule (concat its-zenkaku-escape "'") "$B!G(B") - (its-defrule (concat its-zenkaku-escape "<") "$B!c(B") - (its-defrule (concat its-zenkaku-escape ">") "$B!d(B") - (its-defrule (concat its-zenkaku-escape "?") "$B!)(B") - (its-defrule (concat its-zenkaku-escape "/") "$B!?(B") - (its-defrule (concat its-zenkaku-escape ",") "$B!$(B") - (its-defrule (concat its-zenkaku-escape ".") "$B!%(B") - -;;; -;;; Hankaku inputs -;;; - - (dolist (digit '( "1" "2" "3" "4" "5" "6" "7" "8" "9" "0" )) - (its-defrule (concat its-hankaku-escape digit) digit)) - - (dolist (symbol '( " " "!" "@" "#" "$" "%" "^" "&" "*" "(" ")" - "-" "=" "`" "\\" "|" "_" "+" "~" "[" "]" "{" "}" - ":" ";" "\"" "'" "<" ">" "?" "/" "," "." )) - (its-defrule (concat its-hankaku-escape symbol) symbol)) - - (dolist (downcase '("a" "b" "c" "d" "e" "f" "g" "h" "i" "j" "k" "l" "m" "n" - "o" "p" "q" "r" "s" "t" "u" "v" "w" "x" "y" "z")) - (its-defrule (concat its-hankaku-escape downcase) downcase)) - - (dolist (upcase '("A" "B" "C" "D" "E" "F" "G" "H" "I" "J" "K" "L" "M" "N" - "O" "P" "Q" "R" "S" "T" "U" "V" "W" "X" "Y" "Z")) - (its-defrule (concat its-hankaku-escape upcase) upcase)) - -;; SYMBOL Input - (its-defrule "z1" "$B!{(B") (its-defrule "z!" "$B!|(B") - (its-defrule "z2" "$B"&(B") (its-defrule "z@" "$B"'(B") - (its-defrule "z3" "$B"$(B") (its-defrule "z#" "$B"%(B") - (its-defrule "z4" "$B""(B") (its-defrule "z$" "$B"#(B") - (its-defrule "z5" "$B!~(B") (its-defrule "z%" "$B"!(B") - (its-defrule "z6" "$B!y(B") (its-defrule "z^" "$B!z(B") - (its-defrule "z7" "$B!}(B") (its-defrule "z&" "$B!r(B") - (its-defrule "z8" "$B!q(B") (its-defrule "z*" "$B!_(B") - (its-defrule "z9" "$B!i(B") (its-defrule "z(" "$B!Z(B") - (its-defrule "z0" "$B!j(B") (its-defrule "z)" "$B![(B") - (its-defrule "z-" "$B!A(B") (its-defrule "z_" "$B!h(B") - (its-defrule "z=" "$B!b(B") (its-defrule "z+" "$B!^(B") - (its-defrule "z\\" "$B!@(B") (its-defrule "z|" "$B!B(B") - (its-defrule "z`" "$B!-(B") (its-defrule "z~" "$B!/(B") - - (its-defrule "zq" "$B!T(B") (its-defrule "zQ" "$B!R(B") - (its-defrule "zw" "$B!U(B") (its-defrule "zW" "$B!S(B") - ; e - (its-defrule "zr" "$B!9(B") (its-defrule "zR" "$B!8(B") - (its-defrule "zt" "$B!:(B") (its-defrule "zT" "$B!x(B") - ; y u i o - (its-defrule "zp" "$B")(B") (its-defrule "zP" "$B",(B") - (its-defrule "z[" "$B!X(B") (its-defrule "z{" "$B!L(B") - (its-defrule "z]" "$B!Y(B") (its-defrule "z}" "$B!M(B") - - ; a - (its-defrule "zs" "$B!3(B") (its-defrule "zS" "$B!4(B") - (its-defrule "zd" "$B!5(B") (its-defrule "zD" "$B!6(B") - (its-defrule "zf" "$B!7(B") (its-defrule "zF" "$B"*(B") - (its-defrule "zg" "$B!>(B") (its-defrule "zG" "$B!=(B") - (its-defrule "zh" "$B"+(B") - (its-defrule "zj" "$B"-(B") - (its-defrule "zk" "$B",(B") - (its-defrule "zl" "$B"*(B") - (its-defrule "z;" "$B!+(B") (its-defrule "z:" "$B!,(B") - (its-defrule "z\'" "$B!F(B") (its-defrule "z\"" "$B!H(B") - - ; z - (its-defrule "zx" ":-") (its-defrule "zX" ":-)") - (its-defrule "zc" "$B!;(B") (its-defrule "zC" "$B!n(B") - (its-defrule "zv" "$B"((B") (its-defrule "zV" "$B!`(B") - (its-defrule "zb" "$B!k(B") (its-defrule "zB" "$B"+(B") - (its-defrule "zn" "$B!l(B") (its-defrule "zN" "$B"-(B") - (its-defrule "zm" "$B!m(B") (its-defrule "zM" "$B".(B") - (its-defrule "z," "$B!E(B") (its-defrule "z<" "$B!e(B") - (its-defrule "z." "$B!D(B") (its-defrule "z>" "$B!f(B") - (its-defrule "z/" "$B!&(B") (its-defrule "z?" "$B!g(B") - ) - -(define-its-state-machine-append its-kata-map - (if its-kata-enable-double-n - (its-defrule "nn" "$B%s(B") - (its-defrule "nn" "$B%s(B" -1)) - - (its-defrule "-" its-kata-horizontal) - (its-defrule "[" its-kata-open-bracket) - (its-defrule "]" its-kata-close-bracket) - (its-defrule "." its-kata-period) - (its-defrule "," its-kata-comma) - - (if its-kata-enable-zenkaku-alphabet - (progn - (its-defrule "1" "$B#1(B") (its-defrule "2" "$B#2(B") - (its-defrule "3" "$B#3(B") (its-defrule "4" "$B#4(B") - (its-defrule "5" "$B#5(B") (its-defrule "6" "$B#6(B") - (its-defrule "7" "$B#7(B") (its-defrule "8" "$B#8(B") - (its-defrule "9" "$B#9(B") (its-defrule "0" "$B#0(B") - (its-defrule "!" "$B!*(B") (its-defrule "@" "$B!w(B") - (its-defrule "#" "$B!t(B") (its-defrule "$" "$B!p(B") - (its-defrule "%" "$B!s(B") (its-defrule "^" "$B!0(B") - (its-defrule "&" "$B!u(B") (its-defrule "*" "$B!v(B") - (its-defrule "(" "$B!J(B") (its-defrule ")" "$B!K(B") - (its-defrule "=" "$B!a(B") (its-defrule "`" "$B!.(B") - (its-defrule "\\" "$B!o(B") (its-defrule "|" "$B!C(B") - (its-defrule "_" "$B!2(B") (its-defrule "+" "$B!\(B") - (its-defrule "{" "$B!P(B") (its-defrule "}" "$B!Q(B") - (its-defrule ":" "$B!'(B") (its-defrule ";" "$B!((B") - (its-defrule "\"" "$B!I(B") (its-defrule "'" "$B!G(B") - (its-defrule "<" "$B!c(B") (its-defrule ">" "$B!d(B") - (its-defrule "?" "$B!)(B") (its-defrule "/" "$B!?(B")) - (progn - (its-defrule "1" "1") (its-defrule "2" "2") - (its-defrule "3" "3") (its-defrule "4" "4") - (its-defrule "5" "5") (its-defrule "6" "6") - (its-defrule "7" "7") (its-defrule "8" "8") - (its-defrule "9" "9") (its-defrule "0" "0") - (its-defrule "!" "!") (its-defrule "@" "@") - (its-defrule "#" "#") (its-defrule "$" "$") - (its-defrule "%" "%") (its-defrule "^" "^") - (its-defrule "&" "&") (its-defrule "*" "*") - (its-defrule "(" "(") (its-defrule ")" ")") - (its-defrule "=" "=") (its-defrule "`" "`") - (its-defrule "\\" "\\") (its-defrule "|" "|") - (its-defrule "_" "_") (its-defrule "+" "+") - (its-defrule "{" "{") (its-defrule "}" "}") - (its-defrule ":" ":") (its-defrule ";" ";") - (its-defrule "\"" "\"") (its-defrule "'" "'") - (its-defrule "<" "<") (its-defrule ">" ">") - (its-defrule "?" "?") (its-defrule "/" "/"))) - ) - -(provide 'its/kata) -;;; its/kata.el ends here. diff --git a/its/quanjiao.el b/its/quanjiao.el deleted file mode 100644 index d33205d..0000000 --- a/its/quanjiao.el +++ /dev/null @@ -1,169 +0,0 @@ -;;; its/quanjiao.el --- Quanjiao ASCII Input in Egg Input Method Architecture - -;; Copyright (C) 1997, 1998 Mule Project, -;; Powered by Electrotechnical Laboratory, JAPAN. -;; Project Leader: Satoru Tomura - -;; Author: KATAYAMA Yoshio - -;; This file will be part of GNU Emacs (in future). - -;; GNU Emacs is free software; you can redistribute it and/or modify -;; it under the terms of the GNU General Public License as published by -;; the Free Software Foundation; either version 2, or (at your option) -;; any later version. - -;; GNU Emacs is distributed in the hope that it will be useful, -;; but WITHOUT ANY WARRANTY; without even the implied warranty of -;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -;; GNU General Public License for more details. - -;; You should have received a copy of the GNU General Public License -;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. - -;;; Commentary: -;; -;; Symbol input is desined by jiro@math.keio.ac.jp (TANAKA Jiro) -;; This file is based on the rules of its/hira.el in Mule-2.3 distribution. -;; - -;;; Code: - -(eval-when-compile - (require 'its)) - -(define-its-state-machine its-quanjiao-up-cn-map - "quanjiao-upcase-cn" "$A#A(B" "Chinese-GB" nil - "Map for quanjiao-upcase input. (Chinese-GB)" - - (dolist (ascii '(("0" . "$A#0(B") ("1" . "$A#1(B") ("2" . "$A#2(B") ("3" . "$A#3(B") - ("4" . "$A#4(B") ("5" . "$A#5(B") ("6" . "$A#6(B") ("7" . "$A#7(B") - ("8" . "$A#8(B") ("9" . "$A#9(B") - (" " . "$A!!(B") ("!" . "$A#!(B") ("@" . "$A#@(B") ("#" . "$A##(B") - ("$" . "$A!g(B") ("%" . "$A#%(B") ("^" . "$A#^(B") ("&" . "$A#&(B") - ("*" . "$A#*(B") ("(" . "$A#((B") (")" . "$A#)(B") - ("-" . "$A#-(B") ("=" . "$A#=(B") ("`" . "$A#`(B") ("\\" . "$A#\(B") - ("|" . "$A#|(B") ("_" . "$A#_(B") ("+" . "$A#+(B") ("~" . "$A!+(B") - ("[" . "$A#[(B") ("]" . "$A#](B") ("{" . "$A#{(B") ("}" . "$A#}(B") - (":" . "$A#:(B") (";" . "$A#;(B") ("\"" . "$A#"(B") ("'" . "$A#'(B") - ("<" . "$A#<(B") (">" . "$A#>(B") ("?" . "$A#?(B") ("/" . "$A#/(B") - ("," . "$A#,(B") ("." . "$A#.(B") - ("a" . "$A#A(B") ("b" . "$A#B(B") ("c" . "$A#C(B") ("d" . "$A#D(B") - ("e" . "$A#E(B") ("f" . "$A#F(B") ("g" . "$A#G(B") ("h" . "$A#H(B") - ("i" . "$A#I(B") ("j" . "$A#J(B") ("k" . "$A#K(B") ("l" . "$A#L(B") - ("m" . "$A#M(B") ("n" . "$A#N(B") ("o" . "$A#O(B") ("p" . "$A#P(B") - ("q" . "$A#Q(B") ("r" . "$A#R(B") ("s" . "$A#S(B") ("t" . "$A#T(B") - ("u" . "$A#U(B") ("v" . "$A#V(B") ("w" . "$A#W(B") ("x" . "$A#X(B") - ("y" . "$A#Y(B") ("z" . "$A#Z(B") - ("A" . "$A#A(B") ("B" . "$A#B(B") ("C" . "$A#C(B") ("D" . "$A#D(B") - ("E" . "$A#E(B") ("F" . "$A#F(B") ("G" . "$A#G(B") ("H" . "$A#H(B") - ("I" . "$A#I(B") ("J" . "$A#J(B") ("K" . "$A#K(B") ("L" . "$A#L(B") - ("M" . "$A#M(B") ("N" . "$A#N(B") ("O" . "$A#O(B") ("P" . "$A#P(B") - ("Q" . "$A#Q(B") ("R" . "$A#R(B") ("S" . "$A#S(B") ("T" . "$A#T(B") - ("U" . "$A#U(B") ("V" . "$A#V(B") ("W" . "$A#W(B") ("X" . "$A#X(B") - ("Y" . "$A#Y(B") ("Z" . "$A#Z(B"))) - (let ((in (car ascii)) (out (cdr ascii))) - (its-defrule in out)))) - -(define-its-state-machine its-quanjiao-down-cn-map - "quanjiao-downcase-cn" "$A#a(B" "Chinese-GB" nil - "Map for quanjiao-downcase input. (Chinese-GB)" - - (dolist (ascii '(("0" . "$A#0(B") ("1" . "$A#1(B") ("2" . "$A#2(B") ("3" . "$A#3(B") - ("4" . "$A#4(B") ("5" . "$A#5(B") ("6" . "$A#6(B") ("7" . "$A#7(B") - ("8" . "$A#8(B") ("9" . "$A#9(B") - (" " . "$A!!(B") ("!" . "$A#!(B") ("@" . "$A#@(B") ("#" . "$A##(B") - ("$" . "$A!g(B") ("%" . "$A#%(B") ("^" . "$A#^(B") ("&" . "$A#&(B") - ("*" . "$A#*(B") ("(" . "$A#((B") (")" . "$A#)(B") - ("-" . "$A#-(B") ("=" . "$A#=(B") ("`" . "$A#`(B") ("\\" . "$A#\(B") - ("|" . "$A#|(B") ("_" . "$A#_(B") ("+" . "$A#+(B") ("~" . "$A!+(B") - ("[" . "$A#[(B") ("]" . "$A#](B") ("{" . "$A#{(B") ("}" . "$A#}(B") - (":" . "$A#:(B") (";" . "$A#;(B") ("\"" . "$A#"(B") ("'" . "$A#'(B") - ("<" . "$A#<(B") (">" . "$A#>(B") ("?" . "$A#?(B") ("/" . "$A#/(B") - ("," . "$A#,(B") ("." . "$A#.(B") - ("a" . "$A#a(B") ("b" . "$A#b(B") ("c" . "$A#c(B") ("d" . "$A#d(B") - ("e" . "$A#e(B") ("f" . "$A#f(B") ("g" . "$A#g(B") ("h" . "$A#h(B") - ("i" . "$A#i(B") ("j" . "$A#j(B") ("k" . "$A#k(B") ("l" . "$A#l(B") - ("m" . "$A#m(B") ("n" . "$A#n(B") ("o" . "$A#o(B") ("p" . "$A#p(B") - ("q" . "$A#q(B") ("r" . "$A#r(B") ("s" . "$A#s(B") ("t" . "$A#t(B") - ("u" . "$A#u(B") ("v" . "$A#v(B") ("w" . "$A#w(B") ("x" . "$A#x(B") - ("y" . "$A#y(B") ("z" . "$A#z(B") - ("A" . "$A#A(B") ("B" . "$A#B(B") ("C" . "$A#C(B") ("D" . "$A#D(B") - ("E" . "$A#E(B") ("F" . "$A#F(B") ("G" . "$A#G(B") ("H" . "$A#H(B") - ("I" . "$A#I(B") ("J" . "$A#J(B") ("K" . "$A#K(B") ("L" . "$A#L(B") - ("M" . "$A#M(B") ("N" . "$A#N(B") ("O" . "$A#O(B") ("P" . "$A#P(B") - ("Q" . "$A#Q(B") ("R" . "$A#R(B") ("S" . "$A#S(B") ("T" . "$A#T(B") - ("U" . "$A#U(B") ("V" . "$A#V(B") ("W" . "$A#W(B") ("X" . "$A#X(B") - ("Y" . "$A#Y(B") ("Z" . "$A#Z(B"))) - (let ((in (car ascii)) (out (cdr ascii))) - (its-defrule in out)))) - -(define-its-state-machine its-quanjiao-up-tw-map - "quanjiao-upcase-tw" "$(G$A(B" "Chinese-CNS" nil - "Map for quanjiao-upcase input. (Chinese-CNS)" - - (dolist (ascii '(("0" . "$(G$!(B") ("1" . "$(G$"(B") ("2" . "$(G$#(B") ("3" . "$(G$$(B") - ("4" . "$(G$%(B") ("5" . "$(G$&(B") ("6" . "$(G$'(B") ("7" . "$(G$((B") - ("8" . "$(G$)(B") ("9" . "$(G$*(B") - (" " . "$(G!!(B") ("!" . "$(G!*(B") ("@" . "$(G"i(B") ("#" . "$(G!l(B") - ("$" . "$(G"c(B") ("%" . "$(G"h(B") ("^" . "$(G!T(B") ("&" . "$(G!m(B") - ("*" . "$(G!n(B") ("(" . "$(G!>(B") (")" . "$(G!?(B") - ("-" . "$(G"1(B") ("=" . "$(G"8(B") ("`" . "$(G!j(B") ("\\" . "$(G"b(B") - ("|" . "$(G"^(B") ("_" . "$(G"%(B") ("+" . "$(G"0(B") ("~" . "$(G"D(B") - ("[" . "$(G!b(B") ("]" . "$(G!c(B") ("{" . "$A#{(B") ("}" . "$(G!a(B") - (":" . "$(G!((B") (";" . "$(G!'(B") ("\"" . "$(G!i(B") ("'" . "$(G!k(B") - ("<" . "$(G"6(B") (">" . "$(G"7(B") ("?" . "$(G!)(B") ("/" . "$(G"a(B") - ("," . "$(G!"(B") ("." . "$(G!%(B") - ("a" . "$(G$A(B") ("b" . "$(G$B(B") ("c" . "$(G$C(B") ("d" . "$(G$D(B") - ("e" . "$(G$E(B") ("f" . "$(G$F(B") ("g" . "$(G$G(B") ("h" . "$(G$H(B") - ("i" . "$(G$I(B") ("j" . "$(G$J(B") ("k" . "$(G$K(B") ("l" . "$(G$L(B") - ("m" . "$(G$M(B") ("n" . "$(G$N(B") ("o" . "$(G$O(B") ("p" . "$(G$P(B") - ("q" . "$(G$Q(B") ("r" . "$(G$R(B") ("s" . "$(G$S(B") ("t" . "$(G$T(B") - ("u" . "$(G$U(B") ("v" . "$(G$V(B") ("w" . "$(G$W(B") ("x" . "$(G$X(B") - ("y" . "$(G$Y(B") ("z" . "$(G$Z(B") - ("A" . "$(G$A(B") ("B" . "$(G$B(B") ("C" . "$(G$C(B") ("D" . "$(G$D(B") - ("E" . "$(G$E(B") ("F" . "$(G$F(B") ("G" . "$(G$G(B") ("H" . "$(G$H(B") - ("I" . "$(G$I(B") ("J" . "$(G$J(B") ("K" . "$(G$K(B") ("L" . "$(G$L(B") - ("M" . "$(G$M(B") ("N" . "$(G$N(B") ("O" . "$(G$O(B") ("P" . "$(G$P(B") - ("Q" . "$(G$Q(B") ("R" . "$(G$R(B") ("S" . "$(G$S(B") ("T" . "$(G$T(B") - ("U" . "$(G$U(B") ("V" . "$(G$V(B") ("W" . "$(G$W(B") ("X" . "$(G$X(B") - ("Y" . "$(G$Y(B") ("Z" . "$(G$Z(B"))) - (let ((in (car ascii)) (out (cdr ascii))) - (its-defrule in out)))) - -(define-its-state-machine its-quanjiao-down-tw-map - "quanjiao-downcase-tw" "$(G$[(B" "Chinese-CNS" nil - "Map for quanjiao-downcase input. (Chinese-CNS)" - - (dolist (ascii '(("0" . "$(G$!(B") ("1" . "$(G$"(B") ("2" . "$(G$#(B") ("3" . "$(G$$(B") - ("4" . "$(G$%(B") ("5" . "$(G$&(B") ("6" . "$(G$'(B") ("7" . "$(G$((B") - ("8" . "$(G$)(B") ("9" . "$(G$*(B") - (" " . "$(G!!(B") ("!" . "$(G!*(B") ("@" . "$(G"i(B") ("#" . "$(G!l(B") - ("$" . "$(G"c(B") ("%" . "$(G"h(B") ("^" . "$(G!T(B") ("&" . "$(G!m(B") - ("*" . "$(G!n(B") ("(" . "$(G!>(B") (")" . "$(G!?(B") - ("-" . "$(G"1(B") ("=" . "$(G"8(B") ("`" . "$(G!j(B") ("\\" . "$(G"b(B") - ("|" . "$(G"^(B") ("_" . "$(G"%(B") ("+" . "$(G"0(B") ("~" . "$(G"D(B") - ("[" . "$(G!b(B") ("]" . "$(G!c(B") ("{" . "$A#{(B") ("}" . "$(G!a(B") - (":" . "$(G!((B") (";" . "$(G!'(B") ("\"" . "$(G!i(B") ("'" . "$(G!k(B") - ("<" . "$(G"6(B") (">" . "$(G"7(B") ("?" . "$(G!)(B") ("/" . "$(G"a(B") - ("," . "$(G!"(B") ("." . "$(G!%(B") - ("a" . "$(G$[(B") ("b" . "$(G$\(B") ("c" . "$(G$](B") ("d" . "$(G$^(B") - ("e" . "$(G$_(B") ("f" . "$(G$`(B") ("g" . "$(G$a(B") ("h" . "$(G$b(B") - ("i" . "$(G$c(B") ("j" . "$(G$d(B") ("k" . "$(G$e(B") ("l" . "$(G$f(B") - ("m" . "$(G$g(B") ("n" . "$(G$h(B") ("o" . "$(G$i(B") ("p" . "$(G$j(B") - ("q" . "$(G$k(B") ("r" . "$(G$l(B") ("s" . "$(G$m(B") ("t" . "$(G$n(B") - ("u" . "$(G$o(B") ("v" . "$(G$p(B") ("w" . "$(G$q(B") ("x" . "$(G$r(B") - ("y" . "$(G$s(B") ("z" . "$(G$t(B") - ("A" . "$(G$A(B") ("B" . "$(G$B(B") ("C" . "$(G$C(B") ("D" . "$(G$D(B") - ("E" . "$(G$E(B") ("F" . "$(G$F(B") ("G" . "$(G$G(B") ("H" . "$(G$H(B") - ("I" . "$(G$I(B") ("J" . "$(G$J(B") ("K" . "$(G$K(B") ("L" . "$(G$L(B") - ("M" . "$(G$M(B") ("N" . "$(G$N(B") ("O" . "$(G$O(B") ("P" . "$(G$P(B") - ("Q" . "$(G$Q(B") ("R" . "$(G$R(B") ("S" . "$(G$S(B") ("T" . "$(G$T(B") - ("U" . "$(G$U(B") ("V" . "$(G$V(B") ("W" . "$(G$W(B") ("X" . "$(G$X(B") - ("Y" . "$(G$Y(B") ("Z" . "$(G$Z(B"))) - (let ((in (car ascii)) (out (cdr ascii))) - (its-defrule in out)))) - -(provide 'its/quanjiao) diff --git a/its/zenkaku.el b/its/zenkaku.el deleted file mode 100644 index d56c1bb..0000000 --- a/its/zenkaku.el +++ /dev/null @@ -1,103 +0,0 @@ -;;; its/zenkau.el --- Zenkaku ASCII Input in Egg Input Method Architecture - -;; Copyright (C) 1997, 1998 Mule Project, -;; Powered by Electrotechnical Laboratory, JAPAN. -;; Project Leader: Satoru Tomura - -;; Author: KATAYAMA Yoshio - -;; This file will be part of GNU Emacs (in future). - -;; GNU Emacs is free software; you can redistribute it and/or modify -;; it under the terms of the GNU General Public License as published by -;; the Free Software Foundation; either version 2, or (at your option) -;; any later version. - -;; GNU Emacs is distributed in the hope that it will be useful, -;; but WITHOUT ANY WARRANTY; without even the implied warranty of -;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -;; GNU General Public License for more details. - -;; You should have received a copy of the GNU General Public License -;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. - -;;; Commentary: -;; -;; Symbol input is desined by jiro@math.keio.ac.jp (TANAKA Jiro) -;; This file is based on the rules of its/hira.el in Mule-2.3 distribution. -;; - -;;; Code: - -(eval-when-compile - (require 'its)) - -(define-its-state-machine its-zenkaku-up-map - "zenkaku-upcase" "$B#A(B" "Japanese" nil - "Map for zenkaku-upcase input." - - (dolist (ascii '(("0" . "$B#0(B") ("1" . "$B#1(B") ("2" . "$B#2(B") ("3" . "$B#3(B") - ("4" . "$B#4(B") ("5" . "$B#5(B") ("6" . "$B#6(B") ("7" . "$B#7(B") - ("8" . "$B#8(B") ("9" . "$B#9(B") - (" " . "$B!!(B") ("!" . "$B!*(B") ("@" . "$B!w(B") ("#" . "$B!t(B") - ("$" . "$B!p(B") ("%" . "$B!s(B") ("^" . "$B!0(B") ("&" . "$B!u(B") - ("*" . "$B!v(B") ("(" . "$B!J(B") (")" . "$B!K(B") - ("-" . "$B!](B") ("=" . "$B!a(B") ("`" . "$B!.(B") ("\\" . "$B!@(B") - ("|" . "$B!C(B") ("_" . "$B!2(B") ("+" . "$B!\(B") ("~" . "$B!A(B") - ("[" . "$B!N(B") ("]" . "$B!O(B") ("{" . "$B!P(B") ("}" . "$B!Q(B") - (":" . "$B!'(B") (";" . "$B!((B") ("\"" . "$B!I(B") ("'" . "$B!-(B") - ("<" . "$B!c(B") (">" . "$B!d(B") ("?" . "$B!)(B") ("/" . "$B!?(B") - ("," . "$B!$(B") ("." . "$B!%(B") - ("a" . "$B#A(B") ("b" . "$B#B(B") ("c" . "$B#C(B") ("d" . "$B#D(B") - ("e" . "$B#E(B") ("f" . "$B#F(B") ("g" . "$B#G(B") ("h" . "$B#H(B") - ("i" . "$B#I(B") ("j" . "$B#J(B") ("k" . "$B#K(B") ("l" . "$B#L(B") - ("m" . "$B#M(B") ("n" . "$B#N(B") ("o" . "$B#O(B") ("p" . "$B#P(B") - ("q" . "$B#Q(B") ("r" . "$B#R(B") ("s" . "$B#S(B") ("t" . "$B#T(B") - ("u" . "$B#U(B") ("v" . "$B#V(B") ("w" . "$B#W(B") ("x" . "$B#X(B") - ("y" . "$B#Y(B") ("z" . "$B#Z(B") - ("A" . "$B#A(B") ("B" . "$B#B(B") ("C" . "$B#C(B") ("D" . "$B#D(B") - ("E" . "$B#E(B") ("F" . "$B#F(B") ("G" . "$B#G(B") ("H" . "$B#H(B") - ("I" . "$B#I(B") ("J" . "$B#J(B") ("K" . "$B#K(B") ("L" . "$B#L(B") - ("M" . "$B#M(B") ("N" . "$B#N(B") ("O" . "$B#O(B") ("P" . "$B#P(B") - ("Q" . "$B#Q(B") ("R" . "$B#R(B") ("S" . "$B#S(B") ("T" . "$B#T(B") - ("U" . "$B#U(B") ("V" . "$B#V(B") ("W" . "$B#W(B") ("X" . "$B#X(B") - ("Y" . "$B#Y(B") ("Z" . "$B#Z(B"))) - (let ((in (car ascii)) (out (cdr ascii))) - (its-defrule in out)))) - -(define-its-state-machine its-zenkaku-down-map - "zenkaku-downcase" "$B#a(B" "Japanese" nil - "Map for zenkaku-downcase input." - - (dolist (ascii '(("0" . "$B#0(B") ("1" . "$B#1(B") ("2" . "$B#2(B") ("3" . "$B#3(B") - ("4" . "$B#4(B") ("5" . "$B#5(B") ("6" . "$B#6(B") ("7" . "$B#7(B") - ("8" . "$B#8(B") ("9" . "$B#9(B") - (" " . "$B!!(B") ("!" . "$B!*(B") ("@" . "$B!w(B") ("#" . "$B!t(B") - ("$" . "$B!p(B") ("%" . "$B!s(B") ("^" . "$B!0(B") ("&" . "$B!u(B") - ("*" . "$B!v(B") ("(" . "$B!J(B") (")" . "$B!K(B") - ("-" . "$B!](B") ("=" . "$B!a(B") ("`" . "$B!.(B") ("\\" . "$B!@(B") - ("|" . "$B!C(B") ("_" . "$B!2(B") ("+" . "$B!\(B") ("~" . "$B!A(B") - ("[" . "$B!N(B") ("]" . "$B!O(B") ("{" . "$B!P(B") ("}" . "$B!Q(B") - (":" . "$B!'(B") (";" . "$B!((B") ("\"" . "$B!I(B") ("'" . "$B!-(B") - ("<" . "$B!c(B") (">" . "$B!d(B") ("?" . "$B!)(B") ("/" . "$B!?(B") - ("," . "$B!$(B") ("." . "$B!%(B") - ("a" . "$B#a(B") ("b" . "$B#b(B") ("c" . "$B#c(B") ("d" . "$B#d(B") - ("e" . "$B#e(B") ("f" . "$B#f(B") ("g" . "$B#g(B") ("h" . "$B#h(B") - ("i" . "$B#i(B") ("j" . "$B#j(B") ("k" . "$B#k(B") ("l" . "$B#l(B") - ("m" . "$B#m(B") ("n" . "$B#n(B") ("o" . "$B#o(B") ("p" . "$B#p(B") - ("q" . "$B#q(B") ("r" . "$B#r(B") ("s" . "$B#s(B") ("t" . "$B#t(B") - ("u" . "$B#u(B") ("v" . "$B#v(B") ("w" . "$B#w(B") ("x" . "$B#x(B") - ("y" . "$B#y(B") ("z" . "$B#z(B") - ("A" . "$B#A(B") ("B" . "$B#B(B") ("C" . "$B#C(B") ("D" . "$B#D(B") - ("E" . "$B#E(B") ("F" . "$B#F(B") ("G" . "$B#G(B") ("H" . "$B#H(B") - ("I" . "$B#I(B") ("J" . "$B#J(B") ("K" . "$B#K(B") ("L" . "$B#L(B") - ("M" . "$B#M(B") ("N" . "$B#N(B") ("O" . "$B#O(B") ("P" . "$B#P(B") - ("Q" . "$B#Q(B") ("R" . "$B#R(B") ("S" . "$B#S(B") ("T" . "$B#T(B") - ("U" . "$B#U(B") ("V" . "$B#V(B") ("W" . "$B#W(B") ("X" . "$B#X(B") - ("Y" . "$B#Y(B") ("Z" . "$B#Z(B"))) - (let ((in (car ascii)) (out (cdr ascii))) - (its-defrule in out)))) - -(provide 'its/zenkaku) diff --git a/its/zhuyin.el b/its/zhuyin.el deleted file mode 100644 index 442834b..0000000 --- a/its/zhuyin.el +++ /dev/null @@ -1,288 +0,0 @@ -;;; its/zhuyin.el --- Zhuyin Input in Egg Input Method Architecture - -;; Copyright (C) 1997, 1998 Mule Project, -;; Powered by Electrotechnical Laboratory, JAPAN. -;; Project Leader: Satoru Tomura - -;; Author: KATAYAMA Yoshio - -;; This file will be part of GNU Emacs (in future). - -;; GNU Emacs is free software; you can redistribute it and/or modify -;; it under the terms of the GNU General Public License as published by -;; the Free Software Foundation; either version 2, or (at your option) -;; any later version. - -;; GNU Emacs is distributed in the hope that it will be useful, -;; but WITHOUT ANY WARRANTY; without even the implied warranty of -;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -;; GNU General Public License for more details. - -;; You should have received a copy of the GNU General Public License -;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. - -;;; Commentary: - - -;;; Code: - -(eval-when-compile - (require 'its) - (require 'cl)) - -(defvar its-zhuyin-cn-enable-quanjioao-alphabet t "*Enable Quanjiao alphabet") -(defvar its-zhuyin-cn-open-braket "$A!8(B" "*[") ; "$A#[(B" -(defvar its-zhuyin-cn-close-braket "$A!9(B" "*]") ; "$A#](B" - -(defvar its-zhuyin-tw-enable-quanjioao-alphabet t "*Enable Quanjiao alphabet") -(defvar its-zhuyin-tw-open-braket "$(G!V(B" "*[") ; "$(G!b(B " -(defvar its-zhuyin-tw-close-braket "$(G!W(B" "*]") ; "$(G!c(B" - -(eval-when-compile - (defmacro its-do-zhuyin-table (list) - `(progn - ,@(mapcar (lambda (syl) `(its-define-zhuyin ,@syl)) - list))) - - (defmacro its-define-zhuyin (shengmu yunmu1 &optional yunmu2 qing-only) - `(let ((s (list ,@shengmu)) - (yi (concat (car ,yunmu1) (car ,yunmu2))) - (yo (concat (nth 1 ,yunmu1) (nth 1 ,yunmu2))) - (tone (if ,qing-only "(0A(B" "(0@(B")) - in out out1 state) - (while s - (setq in (concat (car (car s)) yi) - out (concat (nth 1 (car s)) yo) - out1 (concat out tone) - state (its-goto-state in nil t)) - (if (and ,qing-only (its-get-kst/t state)) - (its-set-output state out) - (its-set-output state out1)) - (its-make-next-state state -1 in out1) - (its-make-next-state state ? (concat in " ") out1) - (its-define-otherwise state (its-make-otherwise - out1 - its-otherwise-back-one)) - ,(if qing-only - nil - '(progn - (its-make-next-state state ?1 (concat in 1) (concat out "(0A(B")) - (its-make-next-state state ?2 (concat in 2) (concat out "(0B(B")) - (its-make-next-state state ?3 (concat in 3) (concat out "(0C(B")) - (its-make-next-state state ?4 (concat in 4) (concat out "(0D(B")))) - (setq s (cdr s))))) - - (defmacro its-define-zhuyin-table () - '(let ((- '("" "")) - (B '("b" "(0E(B")) (P '("p" "(0F(B")) (M '("m" "(0G(B")) (F '("f" "(0H(B")) - (D '("d" "(0I(B")) (T '("t" "(0J(B")) (N '("n" "(0K(B")) (L '("l" "(0L(B")) - (G '("v" "(0M(B")) (K '("k" "(0N(B")) (H '("h" "(0O(B")) - (J '("g" "(0P(B")) (Q '("7" "(0Q(B")) (X '("c" "(0R(B")) - (ZH '("," "(0S(B")) (CH '("." "(0T(B")) (SH '("/" "(0U(B")) (R '("j" "(0V(B")) - (Z '(";" "(0W(B")) (C '(":" "(0X(B")) (S '("s" "(0Y(B")) - - (A '("a" "(0Z(B")) (O '("o" "(0[(B")) (e '("r" "(0\(B")) (E '("w" "(0](B")) - (AI '("i" "(0^(B")) (EI '("q" "(0_(B")) (AO '("z" "(0`(B")) - (AN '("8" "(0b(B")) (EN '("9" "(0c(B")) (ANG '("0" "(0d(B")) (ENG '("-" "(0e(B")) - (ER '("^" "(0f(B")) (OU '("y" "(0a(B")) - (I '("e" "(0g(B")) (U '("x" "(0h(B")) (V '("u" "(0i(B"))) - - (mapcar (lambda (s) (its-defrule (car s) (nth 1 s))) - (list B P M F D T N L G K H J Q X)) - - (its-do-zhuyin-table - (((- B P M F D T N L G K H ZH CH SH Z C S ) A) - ((- B P M F L ) O) - ((- M D T N L G K H ZH CH SH R Z C S ) e) - ((- B P M D T N L G K H ZH CH SH Z C S ) AI) - ((- B P M F D T N L G K H ZH SH Z C ) EI) - ((- B P M D T N L G K H ZH CH SH R Z C S ) AO) - ((- B P M F D T N L G K H ZH CH SH R Z C S ) AN) - ((- B P M F D N G K H ZH CH SH R Z C S ) EN) - ((- B P M F D T N L G K H ZH CH SH R Z C S ) ANG) - ((- B P M F D T N L G K H ZH CH SH R Z C S ) ENG) - ((- ) ER) - ((- P M F D T N L G K H ZH CH SH R Z C S ) OU) - (( ZH CH SH R Z C S ) -) - ((- B P M D T N L J Q X ) I) - ((- D L J Q X ) I A) - ((- ) I O) - ((- B P M D T N L J Q X ) I E) - ((- B P M D T N L J Q X ) I AO) - ((- M D N L J Q X ) I OU) - ((- B P M D T N L J Q X ) I AN) - ((- B P M N L J Q X ) I EN) - ((- N L J Q X ) I ANG) - ((- B P M D T N L J Q X ) I ENG) - ((- B P M F D T N L G K H ZH CH SH R Z C S ) U) - ((- G K H ZH CH SH R ) U A) - ((- D T N L G K H ZH CH SH R Z C S ) U O) - ((- G K H ZH CH SH ) U AI) - ((- D T G K H ZH CH SH R Z C S ) U EI) - ((- D T N L G K H ZH CH SH R Z C S ) U AN) - ((- D T L G K H ZH CH SH R Z C S ) U EN) - ((- G K H ZH CH SH ) U ANG) - ((- D T N L G K H ZH CH R Z C S ) U ENG) - ((- N L J Q X ) V) - ((- N L J Q X ) V E) - ((- J Q X ) V AN) - ((- J Q X ) V EN) - ((- J Q X ) V ENG) - - ((- H) M nil t) - ((- H) '("@" "@") nil t) - ((- ) N nil t))) - - (its-defrule (concat (car N) 2) (concat (nth 1 N) "(0B(B")) - (its-defrule (concat (car N) 3) (concat (nth 1 N) "(0C(B")) - (its-defrule (concat (car N) 4) (concat (nth 1 N) "(0D(B"))))) - -(define-its-state-machine its-zhuyin-cn-map - "zhuyin-cn" "$AW"(BG" "Chinese-GB" - "Map for Zhuyin input. (Chinese-GB)" - - (defconst its-quanjiao-escape "Z") - (defconst its-banjiao-escape "X") - - (its-defrule-select-mode-temporally "B" downcase) - (its-defrule-select-mode-temporally "Q" quanjiao-downcase-cn) - - (its-define-zhuyin-table) - (dolist (ascii '(("0" . "$A#0(B") ("1" . "$A#1(B") ("2" . "$A#2(B") ("3" . "$A#3(B") - ("4" . "$A#4(B") ("5" . "$A#5(B") ("6" . "$A#6(B") ("7" . "$A#7(B") - ("8" . "$A#8(B") ("9" . "$A#9(B") - (" " . "$A!!(B") ("!" . "$A#!(B") ("@" . "$A#@(B") ("#" . "$A##(B") - ("$" . "$A!g(B") ("%" . "$A#%(B") ("^" . "$A#^(B") ("&" . "$A#&(B") - ("*" . "$A#*(B") ("(" . "$A#((B") (")" . "$A#)(B") - ("-" . "$A#-(B") ("=" . "$A#=(B") ("`" . "$A#`(B") ("\\" . "$A#\(B") - ("|" . "$A#|(B") ("_" . "$A#_(B") ("+" . "$A#+(B") ("~" . "$A!+(B") - ("[" . "$A#[(B") ("]" . "$A#](B") ("{" . "$A#{(B") ("}" . "$A#}(B") - (":" . "$A#:(B") (";" . "$A#;(B") ("\"" . "$A#"(B") ("'" . "$A#'(B") - ("<" . "$A#<(B") (">" . "$A#>(B") ("?" . "$A#?(B") ("/" . "$A#/(B") - ("," . "$A#,(B") ("." . "$A#.(B") - ("a" . "$A#a(B") ("b" . "$A#b(B") ("c" . "$A#c(B") ("d" . "$A#d(B") - ("e" . "$A#e(B") ("f" . "$A#f(B") ("g" . "$A#g(B") ("h" . "$A#h(B") - ("i" . "$A#i(B") ("j" . "$A#j(B") ("k" . "$A#k(B") ("l" . "$A#l(B") - ("m" . "$A#m(B") ("n" . "$A#n(B") ("o" . "$A#o(B") ("p" . "$A#p(B") - ("q" . "$A#q(B") ("r" . "$A#r(B") ("s" . "$A#s(B") ("t" . "$A#t(B") - ("u" . "$A#u(B") ("v" . "$A#v(B") ("w" . "$A#w(B") ("x" . "$A#x(B") - ("y" . "$A#y(B") ("z" . "$A#z(B") - ("A" . "$A#A(B") ("B" . "$A#B(B") ("C" . "$A#C(B") ("D" . "$A#D(B") - ("E" . "$A#E(B") ("F" . "$A#F(B") ("G" . "$A#G(B") ("H" . "$A#H(B") - ("I" . "$A#I(B") ("J" . "$A#J(B") ("K" . "$A#K(B") ("L" . "$A#L(B") - ("M" . "$A#M(B") ("N" . "$A#N(B") ("O" . "$A#O(B") ("P" . "$A#P(B") - ("Q" . "$A#Q(B") ("R" . "$A#R(B") ("S" . "$A#S(B") ("T" . "$A#T(B") - ("U" . "$A#U(B") ("V" . "$A#V(B") ("W" . "$A#W(B") ("X" . "$A#X(B") - ("Y" . "$A#Y(B") ("Z" . "$A#Z(B"))) - (let ((in (car ascii)) (out (cdr ascii))) - (its-defrule (concat its-banjiao-escape in) in) - (its-defrule (concat its-quanjiao-escape in) out))) - - (its-defrule "<" "$A#,(B") - (its-defrule ">" "$A!#(B") - (its-defrule "?" "$A!"(B")) - -(define-its-state-machine its-zhuyin-tw-map - "zhuyin-tw" "$(GNC(BC" "Chinese-CNS" - "Map for Zhuyin input." - - (defconst its-quanjiao-escape "Z") - (defconst its-banjiao-escape "X") - - (its-defrule-select-mode-temporally "B" downcase) - (its-defrule-select-mode-temporally "Q" quanjiao-downcase-tw) - - (its-define-zhuyin-table) - (dolist (ascii '(("0" . "$(G$!(B") ("1" . "$(G$"(B") ("2" . "$(G$#(B") ("3" . "$(G$$(B") - ("4" . "$(G$%(B") ("5" . "$(G$&(B") ("6" . "$(G$'(B") ("7" . "$(G$((B") - ("8" . "$(G$)(B") ("9" . "$(G$*(B") - (" " . "$(G!!(B") ("!" . "$(G!*(B") ("@" . "$(G"i(B") ("#" . "$(G!l(B") - ("$" . "$(G"c(B") ("%" . "$(G"h(B") ("^" . "$(G!T(B") ("&" . "$(G!m(B") - ("*" . "$(G!n(B") ("(" . "$(G!>(B") (")" . "$(G!?(B") - ("-" . "$(G"1(B") ("=" . "$(G"8(B") ("`" . "$(G!j(B") ("\\" . "$(G"b(B") - ("|" . "$(G"^(B") ("_" . "$(G"%(B") ("+" . "$(G"0(B") ("~" . "$(G"D(B") - ("[" . "$(G!b(B") ("]" . "$(G!c(B") ("{" . "$A#{(B") ("}" . "$(G!a(B") - (":" . "$(G!((B") (";" . "$(G!'(B") ("\"" . "$(G!i(B") ("'" . "$(G!k(B") - ("<" . "$(G"6(B") (">" . "$(G"7(B") ("?" . "$(G!)(B") ("/" . "$(G"a(B") - ("," . "$(G!"(B") ("." . "$(G!%(B") - ("a" . "$(G$[(B") ("b" . "$(G$\(B") ("c" . "$(G$](B") ("d" . "$(G$^(B") - ("e" . "$(G$_(B") ("f" . "$(G$`(B") ("g" . "$(G$a(B") ("h" . "$(G$b(B") - ("i" . "$(G$c(B") ("j" . "$(G$d(B") ("k" . "$(G$e(B") ("l" . "$(G$f(B") - ("m" . "$(G$g(B") ("n" . "$(G$h(B") ("o" . "$(G$i(B") ("p" . "$(G$j(B") - ("q" . "$(G$k(B") ("r" . "$(G$l(B") ("s" . "$(G$m(B") ("t" . "$(G$n(B") - ("u" . "$(G$o(B") ("v" . "$(G$p(B") ("w" . "$(G$q(B") ("x" . "$(G$r(B") - ("y" . "$(G$s(B") ("z" . "$(G$t(B") - ("A" . "$(G$A(B") ("B" . "$(G$B(B") ("C" . "$(G$C(B") ("D" . "$(G$D(B") - ("E" . "$(G$E(B") ("F" . "$(G$F(B") ("G" . "$(G$G(B") ("H" . "$(G$H(B") - ("I" . "$(G$I(B") ("J" . "$(G$J(B") ("K" . "$(G$K(B") ("L" . "$(G$L(B") - ("M" . "$(G$M(B") ("N" . "$(G$N(B") ("O" . "$(G$O(B") ("P" . "$(G$P(B") - ("Q" . "$(G$Q(B") ("R" . "$(G$R(B") ("S" . "$(G$S(B") ("T" . "$(G$T(B") - ("U" . "$(G$U(B") ("V" . "$(G$V(B") ("W" . "$(G$W(B") ("X" . "$(G$X(B") - ("Y" . "$(G$Y(B") ("Z" . "$(G$Z(B"))) - (let ((in (car ascii)) (out (cdr ascii))) - (its-defrule (concat its-banjiao-escape in) in) - (its-defrule (concat its-quanjiao-escape in) out))) - - (its-defrule "<" "$(G!"(B") - (its-defrule ">" "$(G!$(B") - (its-defrule "?" "$(G!#(B")) - -(define-its-state-machine-append its-zhuyin-cn-map - (its-defrule "[" its-zhuyin-cn-open-braket nil t) - (its-defrule "]" its-zhuyin-cn-close-braket nil t) - -(if its-zhuyin-cn-enable-quanjioao-alphabet - (progn - (its-defrule "#" "$A##(B") (its-defrule "$" "$A!g(B") - (its-defrule "%" "$A#%(B") - (its-defrule "&" "$A#&(B") (its-defrule "*" "$A#*(B") - (its-defrule "(" "$A#((B") (its-defrule ")" "$A#)(B") - (its-defrule "~" "$A!+(B") - (its-defrule "=" "$A#=(B") (its-defrule "`" "$A#`(B") - (its-defrule "\\" "$A#\(B") (its-defrule "|" "$A#|(B") - (its-defrule "_" "$A#_(B") (its-defrule "+" "$A#+(B") - (its-defrule "{" "$A#{(B") (its-defrule "}" "$A#}(B") - (its-defrule "\"" "$A#"(B") (its-defrule "'" "$A#'(B")) - (progn - (its-defrule "#" "#") (its-defrule "$" "$") - (its-defrule "%" "%") - (its-defrule "&" "&") (its-defrule "*" "*") - (its-defrule "(" "(") (its-defrule ")" ")") - (its-defrule "~" "~") - (its-defrule "=" "=") (its-defrule "`" "`") - (its-defrule "\\" "\\") (its-defrule "|" "|") - (its-defrule "_" "_") (its-defrule "+" "+") - (its-defrule "{" "{") (its-defrule "}" "}") - (its-defrule "\"" "\"") (its-defrule "'" "'")))) - -(define-its-state-machine-append its-zhuyin-tw-map - (its-defrule "[" its-zhuyin-tw-open-braket nil t) - (its-defrule "]" its-zhuyin-tw-close-braket nil t) - - (if its-zhuyin-tw-enable-quanjioao-alphabet - (progn - (its-defrule "#" "$(G!l(B") (its-defrule "$" "$(G"c(B") - (its-defrule "%" "$(G"h(B") - (its-defrule "&" "$(G!m(B") (its-defrule "*" "$(G!n(B") - (its-defrule "(" "$(G!>(B") (its-defrule ")" "$(G!?(B") - (its-defrule "~" "$(G"D(B") - (its-defrule "=" "$(G"8(B") (its-defrule "`" "$(G!j(B") - (its-defrule "\\" "$(G"b(B") (its-defrule "|" "$(G"^(B") - (its-defrule "_" "$(G"%(B") (its-defrule "+" "$(G"0(B") - (its-defrule "{" "$A#{(B") (its-defrule "}" "$(G!a(B") - (its-defrule "\"" "$(G!i(B") (its-defrule "'" "$(G!k(B")) - (progn - (its-defrule "#" "#") (its-defrule "$" "$") - (its-defrule "%" "%") - (its-defrule "&" "&") (its-defrule "*" "*") - (its-defrule "(" "(") (its-defrule ")" ")") - (its-defrule "~" "~") - (its-defrule "=" "=") (its-defrule "`" "`") - (its-defrule "\\" "\\") (its-defrule "|" "|") - (its-defrule "_" "_") (its-defrule "+" "+") - (its-defrule "{" "{") (its-defrule "}" "}") - (its-defrule "\"" "\"") (its-defrule "'" "'")))) - -(provide 'its/zhuyin) -- 1.7.10.4