[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/leim/quail/hangul.el,v
From: |
Kenichi Handa |
Subject: |
[Emacs-diffs] Changes to emacs/leim/quail/hangul.el,v |
Date: |
Sat, 07 Jun 2008 12:42:33 +0000 |
CVSROOT: /cvsroot/emacs
Module name: emacs
Changes by: Kenichi Handa <handa> 08/06/07 12:42:33
Index: hangul.el
===================================================================
RCS file: /cvsroot/emacs/emacs/leim/quail/hangul.el,v
retrieving revision 1.22
retrieving revision 1.23
diff -u -b -r1.22 -r1.23
--- hangul.el 5 Jun 2008 07:23:16 -0000 1.22
+++ hangul.el 7 Jun 2008 12:42:33 -0000 1.23
@@ -31,13 +31,13 @@
(require 'cl)
(require 'hanja-util)
-;; Hangul double jamo table.
+;; Hangul double Jamo table.
;; The format is an alist of JAMO-TYPE vs. DOUBLE-JAMO-TABLE.
;;
;; JAMO-TYPE is a symbol `cho' for Choseong, `jung' for Jungseong, and
;; `jong' for Jongseong.
;;
-;; DOUBLE-JAMO-TABLE is an alist of jamo index vs. the vector of jamo
+;; DOUBLE-JAMO-TABLE is an alist of Jamo index vs. the vector of Jamo
;; indies that can be combined with the car part.
;;
;; Jamo index is a relative index in `hangul Compatibility Jamo' area
@@ -60,7 +60,7 @@
;; Hangul 2-Bulsik keymap.
;; It converts an ASCII code A-Z, a-z, to the corresponding hangul
-;; jamo index.
+;; Jamo index.
(defconst hangul2-keymap
[17 48 26 23 7 9 30 39 33 35 31 51 49 44 32 36 18 1 4 21 37 29 24 28 43 27])
@@ -93,9 +93,10 @@
"Keymap for Hangul method. It is used by all Hangul input method.")
;; Current input character buffer. Store separated hangul character.
-;; First and second index of vector stored "Choseong".
-;; Third and forth index of vector stored "Jungseong".
-;; Fifth and sixth index of vector stored "Jongseong".
+;; The first and second are Choseong position.
+;; The third and forth are Jungseong position.
+;; The fifth and sixth are Jongseong position.
+;; The second, forth and sixth are double Jamo position.
(defvar hangul-queue
(make-vector 6 0))
@@ -159,9 +160,9 @@
(move-overlay quail-overlay (1+ (overlay-start quail-overlay)) (point))))
(defun hangul-djamo (jamo char1 char2)
- "Return the dobule jamo index calculated from the arguments.
-JAMO is a type of Hangul jamo; `cho', `jung', or `jong'.
-CHAR1 and CAHR2 are Hangul jamo indices.
+ "Return the dobule Jamo index calculated from the arguments.
+JAMO is a type of Hangul Jamo; `cho', `jung', or `jong'.
+CHAR1 and CAHR2 are Hangul Jamo indices.
Return nil if CHAR1 and CHAR2 can not combined."
(let* ((jamo (cdr (assoc jamo hangul-djamo-table)))
(char1 (cdr (assoc char1 jamo))))
@@ -176,12 +177,14 @@
0)))
(defsubst hangul2-input-method-jaum (char)
- "Store hangul jamo indice CHAR in `hangul-queue'.
-Maybe, it is a Hangul 2-Bulsik jaum.
-This function processes a Hangul 2-Bulsik jaum.
-Unless the function inserts CHAR to current input queue,
-commit current character and then start next character.
-The Hangul 2-Bulsik is composed of `jaum' and `moum'."
+ "Store Hangul Jamo indice CHAR in `hangul-queue'.
+It is a Hangul 2-Bulsik Jaum.
+This function processes a Hangul 2-Bulsik Jaum.
+The Hangul 2-Bulsik is composed of a Jaum and a Moum.
+The Jaum can be located in a Choseong position and a Jongseong position.
+Unless the function inserts CHAR to `hangul-queue',
+commit current `hangul-queue' and then set a new `hangul-queue',
+and insert CHAR to new `hangul-queue'."
(if (cond ((zerop (aref hangul-queue 0))
(aset hangul-queue 0 char))
((and (zerop (aref hangul-queue 1))
@@ -232,9 +235,10 @@
(setq hangul-queue (vector char 0 0 0 0 0)))))
(defsubst hangul2-input-method-moum (char)
- "Store hangul jamo indice CHAR in `hangul-queue'.
-Maybe, it is a Hangul 2-Bulsik moum.
-This function process a Hangul 2-Bulsik moum.
+ "Store Hangul Jamo indice CHAR in `hangul-queue'.
+It is a Hangul 2-Bulsik Moum.
+This function process a Hangul 2-Bulsik Moum.
+The Moum can be located in a Jungseong position.
Other parts are the same as a `hangul2-input-method-jaum'."
(if (cond ((zerop (aref hangul-queue 2))
(aset hangul-queue 2 char))
@@ -254,10 +258,11 @@
(setq hangul-queue next-char)))))
(defsubst hangul3-input-method-cho (char)
- "Store hangul jamo indice CHAR in `hangul-queue'.
-Maybe, it is a Hangul 3-Bulsik choseong.
-This function process a Hangul 3-Bulsik choseong.
-The Hangul 3-Bulsik is composed of `choseong', `jungseong' and `jongseong'.
+ "Store Hangul Jamo indice CHAR in `hangul-queue'.
+It is a Hangul 3-Bulsik Choseong.
+This function process a Hangul 3-Bulsik Choseong.
+The Hangul 3-Bulsik is composed of a Choseong, a Jungseong and a Jongseong.
+The Choseong can be located in a Choseong position.
Other parts are the same as a `hangul2-input-method-jaum'."
(if (cond ((and (zerop (aref hangul-queue 0))
(zerop (aref hangul-queue 4)))
@@ -271,9 +276,10 @@
(setq hangul-queue (vector char 0 0 0 0 0)))))
(defsubst hangul3-input-method-jung (char)
- "Store hangul jamo indice CHAR in `hangul-queue'.
-Maybe, it is a Hangul 3-Bulsik jungseong.
-This function process a Hangul 3-Bulsik jungseong.
+ "Store Hangul Jamo indice CHAR in `hangul-queue'.
+It is a Hangul 3-Bulsik Jungseong.
+This function process a Hangul 3-Bulsik Jungseong.
+The Jungseong can be located in a Jungseong position.
Other parts are the same as a `hangul3-input-method-cho'."
(if (cond ((and (zerop (aref hangul-queue 2))
(zerop (aref hangul-queue 4)))
@@ -286,9 +292,10 @@
(setq hangul-queue (vector 0 0 char 0 0 0)))))
(defsubst hangul3-input-method-jong (char)
- "Store hangul jamo indice CHAR in `hangul-queue'.
-Maybe, it is a Hangul 3-Bulsik jongseong.
-This function process a Hangul 3-Bulsik jongseong.
+ "Store Hangul Jamo indice CHAR in `hangul-queue'.
+It is a Hangul 3-Bulsik Jongseong.
+This function process a Hangul 3-Bulsik Jongseong.
+The Jongseong can be located in a Jongseong position.
Other parts are the same as a `hangul3-input-method-cho'."
(if (cond ((and (zerop (aref hangul-queue 4))
(notzerop (aref hangul-queue 0))
@@ -334,7 +341,7 @@
(setq hangul-queue (vector 0 0 0 0 char
0))))))
(defun hangul-delete-backward-char ()
- "Delete the previous hangul character by jaso units."
+ "Delete the previous hangul character by Jaso units."
(interactive)
(let ((i 5))
(while (and (> i 0) (zerop (aref hangul-queue i)))