(define-category ?v "Vietnamese")
(define-category ?i "Indian")
(define-category ?o "Lao")
+(define-category ?q "Tibetan")
;; For each group (row) of 2-byte character sets.
(modify-syntax-entry ?\e,Lp\e(B ".")
(modify-syntax-entry ?\e,L}\e(B ".")
+;; Devanagari character set
+
+(let ((deflist '(;; chars syntax category
+ ("\e$(5!!!"!#\e(B" "w" ?7) ; vowel-modifying diacritical mark
+ ; chandrabindu, anuswar, visarga
+ ("\e$(5!$\e(B-\e$(5!2\e(B" "w" ?5) ; independent vowel
+ ("\e$(5!3\e(B-\e$(5!X\e(B" "w" ?0) ; consonant
+ ("\e$(5!Z\e(B-\e$(5!g\e(B" "w" ?8) ; matra
+ ("\e$(5!q\e(B-\e$(5!z\e(B" "w" ?6) ; digit
+ ))
+ elm chars len syntax category to ch i)
+ (while deflist
+ (setq elm (car deflist))
+ (setq chars (car elm)
+ len (length chars)
+ syntax (nth 1 elm)
+ category (nth 2 elm)
+ i 0)
+ (while (< i len)
+ (if (= (aref chars i) ?-)
+ (setq i (1+ i)
+ to (sref chars i))
+ (setq ch (sref chars i)
+ to ch))
+ (while (<= ch to)
+ (modify-syntax-entry ch syntax)
+ (modify-category-entry ch category)
+ (setq ch (1+ ch)))
+ (setq i (+ i (char-bytes to))))
+ (setq deflist (cdr deflist))))
+
;; Ethiopic character set
(modify-category-entry (make-char 'ethiopic) ?e)
(modify-category-entry (make-char 'latin-jisx0201) ?r)
(modify-category-entry (make-char 'japanese-jisx0208) ?j)
(modify-category-entry (make-char 'japanese-jisx0212) ?j)
+(modify-category-entry (make-char 'katakana-jisx0201) ?\|)
(modify-category-entry (make-char 'japanese-jisx0208) ?\|)
+(modify-category-entry (make-char 'japanese-jisx0212) ?\|)
;; JISX0208
(modify-syntax-entry (make-char 'japanese-jisx0208) "w")
(setq i (+ i (char-bytes to))))
(setq deflist (cdr deflist))))
+;; Tibetan character set
+
+(let ((row 33))
+ (while (< row 38)
+ (modify-category-entry (make-char 'tibetan row) ?q)
+ (setq row (1+ row))))
+
+(modify-category-entry (make-char 'tibetan-1-column 33) ?q)
+
+(let ((deflist '(;; chars syntax category
+ ("\e$(7"!\e(B-\e$(7"J\e(B" "w" ?0) ; consonant
+ ("\e$(7#!\e(B-\e$(7#J#P#Q\e(B" "w" ?0) ;
+ ("\e$(7$!\e(B-\e$(7$e\e(B" "w" ?0) ;
+ ("\e$(7%!\e(B-\e$(7%u\e(B" "w" ?0) ;
+ ("\e$(7"S"["\"]"^"a\e(B" "w" ?2) ; upper vowel
+ ("\e$(7"_"c"d"g"h"i"j"k"l\e(B" "w" ?2) ; upper modifier
+ ("\e$(7!I"Q"U"e!e!g\e(B" "w" ?3) ; lowel vowel/modifier
+ ("\e$(7!P\e(B-\e$(7!Y!Z\e(B-\e$(7!c\e(B" "w" ?6) ; digit
+ ("\e$(7!;!=\e(B-\e$(7!B!D"`\e(B" "." ?|) ; line-break char
+ ("\e$(8!;!=!?!@!A!D"`\e(B" "." ?|) ;
+ ("\e$(7!8!;!=\e(B-\e$(7!B!D"`!m!d\e(B" "." ?>) ; prohibition
+ ("\e$(8!;!=!?!@!A!D"`\e(B" "." ?>) ;
+ ("\e$(7!0\e(B-\e$(7!:!l#R#S"f\e(B" "." ?<) ; prohibition
+ ("\e$(7!C!E\e(B-\e$(7!H!J\e(B-\e$(7!O!f!h\e(B-\e$(7!k!n!o\e(B" "." ?q) ; others
+ ))
+ elm chars len syntax category to ch i)
+ (while deflist
+ (setq elm (car deflist))
+ (setq chars (car elm)
+ len (length chars)
+ syntax (nth 1 elm)
+ category (nth 2 elm)
+ i 0)
+ (while (< i len)
+ (if (= (aref chars i) ?-)
+ (setq i (1+ i)
+ to (sref chars i))
+ (setq ch (sref chars i)
+ to ch))
+ (while (<= ch to)
+ (modify-syntax-entry ch syntax)
+ (modify-category-entry ch category)
+ (setq ch (1+ ch)))
+ (setq i (+ i (char-bytes to))))
+ (setq deflist (cdr deflist))))
+
;; Vietnamese character set
(let ((lower (make-char 'vietnamese-viscii-lower))