(modify-syntax-entry (car chars) ".")
(setq chars (cdr chars))))
-;; European character set (Latin-1,2,3,4,5)
-
-(modify-category-entry (make-char 'latin-iso8859-1) ?l)
-(modify-category-entry (make-char 'latin-iso8859-2) ?l)
-(modify-category-entry (make-char 'latin-iso8859-3) ?l)
-(modify-category-entry (make-char 'latin-iso8859-4) ?l)
-(modify-category-entry (make-char 'latin-iso8859-9) ?l)
-(modify-category-entry (make-char 'latin-iso8859-14) ?l)
-(modify-category-entry (make-char 'latin-iso8859-15) ?l)
-
-(modify-category-entry (make-char 'latin-iso8859-1 160) ?\ )
-(modify-category-entry (make-char 'latin-iso8859-2 160) ?\ )
-(modify-category-entry (make-char 'latin-iso8859-3 160) ?\ )
-(modify-category-entry (make-char 'latin-iso8859-4 160) ?\ )
-(modify-category-entry (make-char 'latin-iso8859-9 160) ?\ )
-(modify-category-entry (make-char 'latin-iso8859-14 160) ?\ )
-(modify-category-entry (make-char 'latin-iso8859-15 160) ?\ )
-
;; Greek character set (ISO-8859-7)
(modify-category-entry (make-char 'greek-iso8859-7) ?g)
(modify-category-entry (make-char 'korean-ksc5601 43) ?K)
(modify-category-entry (make-char 'korean-ksc5601 44) ?Y)
+;; Latin character set (latin-1,2,3,4,5,8,9)
+
+(modify-category-entry (make-char 'latin-iso8859-1) ?l)
+(modify-category-entry (make-char 'latin-iso8859-2) ?l)
+(modify-category-entry (make-char 'latin-iso8859-3) ?l)
+(modify-category-entry (make-char 'latin-iso8859-4) ?l)
+(modify-category-entry (make-char 'latin-iso8859-9) ?l)
+(modify-category-entry (make-char 'latin-iso8859-14) ?l)
+(modify-category-entry (make-char 'latin-iso8859-15) ?l)
+
+(modify-category-entry (make-char 'latin-iso8859-1 160) ?\ )
+(modify-category-entry (make-char 'latin-iso8859-2 160) ?\ )
+(modify-category-entry (make-char 'latin-iso8859-3 160) ?\ )
+(modify-category-entry (make-char 'latin-iso8859-4 160) ?\ )
+(modify-category-entry (make-char 'latin-iso8859-9 160) ?\ )
+(modify-category-entry (make-char 'latin-iso8859-14 160) ?\ )
+(modify-category-entry (make-char 'latin-iso8859-15 160) ?\ )
+
;; Lao character set
(modify-category-entry (make-char 'lao) ?o)
tbl)
(setq i (1+ i))))
+;; Unicode (mule-unicode-0100-24ff)
+
+(let ((c #x0100) (tbl (standard-case-table)))
+ (while (<= c #x0233) ; Latin Extended-A, Latin Extended-B
+ (modify-category-entry (decode-char 'ucs c) ?l)
+ (and (<= c #x0176)
+ (zerop (% c 2))
+ (set-case-syntax-pair
+ (decode-char 'ucs c) (decode-char 'ucs (1+ c)) tbl))
+ (setq c (1+ c)))
+ (set-case-syntax-pair ?\e$,1!8\e(B ?\e,A\7f\e(B tbl)
+ (set-case-syntax-pair ?\e$,1!9\e(B ?\e$,1!:\e(B tbl)
+ (set-case-syntax-pair ?\e$,1!;\e(B ?\e$,1!<\e(B tbl)
+ (set-case-syntax-pair ?\e$,1!=\e(B ?\e$,1!>\e(B tbl)
+
+ (setq c #x1e00) ; Latin Extended Additional
+ (while (<= c #x1ef9)
+ (modify-category-entry (decode-char 'ucs c) ?l)
+ (and (zerop (% c 2))
+ (or (<= c #x1e94) (>= c #x1ea0))
+ (set-case-syntax-pair
+ (decode-char 'ucs c) (decode-char 'ucs (1+ c)) tbl))
+ (setq c (1+ c)))
+
+ (setq c #x0370) ; Greek
+ (while (<= c #x03ff)
+ (modify-category-entry (decode-char 'ucs c) ?g)
+ (if (or (and (>= c #x0391) (<= c #x03a1))
+ (and (>= c #x03a3) (<= c #x03ab)))
+ (set-case-syntax-pair
+ (decode-char 'ucs c) (decode-char 'ucs (+ c 32)) tbl))
+ (and (>= c #x03da)
+ (<= c #x03ee)
+ (zerop (% c 2))
+ (set-case-syntax-pair
+ (decode-char 'ucs c) (decode-char 'ucs (1+ c)) tbl))
+ (setq c (1+ c)))
+ (set-case-syntax-pair ?\e$,1&f\e(B ?\e$,1',\e(B tbl)
+ (set-case-syntax-pair ?\e$,1&h\e(B ?\e$,1'-\e(B tbl)
+ (set-case-syntax-pair ?\e$,1&i\e(B ?\e$,1'.\e(B tbl)
+ (set-case-syntax-pair ?\e$,1&j\e(B ?\e$,1'/\e(B tbl)
+ (set-case-syntax-pair ?\e$,1&l\e(B ?\e$,1'L\e(B tbl)
+ (set-case-syntax-pair ?\e$,1&n\e(B ?\e$,1'M\e(B tbl)
+ (set-case-syntax-pair ?\e$,1&o\e(B ?\e$,1'N\e(B tbl)
+
+ (setq c #x1f00) ; Greek Extended
+ (while (<= c #x1fff)
+ (modify-category-entry (decode-char 'ucs c) ?g)
+ (and (<= (logand c #x000f) 7)
+ (<= c #x1fa7)
+ (not (memq c '(#x1f50 #x1f52 #x1f54 #x1f56)))
+ (/= (logand c #x00f0) 7)
+ (set-case-syntax-pair
+ (decode-char 'ucs (+ c 8)) (decode-char 'ucs c) tbl))
+ (setq c (1+ c)))
+ (set-case-syntax-pair ?\e$,1qx\e(B ?\e$,1qp\e(B tbl)
+ (set-case-syntax-pair ?\e$,1qy\e(B ?\e$,1qq\e(B tbl)
+ (set-case-syntax-pair ?\e$,1qz\e(B ?\e$,1q0\e(B tbl)
+ (set-case-syntax-pair ?\e$,1q{\e(B ?\e$,1q1\e(B tbl)
+ (set-case-syntax-pair ?\e$,1q|\e(B ?\e$,1qs\e(B tbl)
+ (set-case-syntax-pair ?\e$,1r(\e(B ?\e$,1q2\e(B tbl)
+ (set-case-syntax-pair ?\e$,1r)\e(B ?\e$,1q3\e(B tbl)
+ (set-case-syntax-pair ?\e$,1r*\e(B ?\e$,1q4\e(B tbl)
+ (set-case-syntax-pair ?\e$,1r+\e(B ?\e$,1q5\e(B tbl)
+ (set-case-syntax-pair ?\e$,1r,\e(B ?\e$,1r#\e(B tbl)
+ (set-case-syntax-pair ?\e$,1r8\e(B ?\e$,1r0\e(B tbl)
+ (set-case-syntax-pair ?\e$,1r9\e(B ?\e$,1r1\e(B tbl)
+ (set-case-syntax-pair ?\e$,1r:\e(B ?\e$,1q6\e(B tbl)
+ (set-case-syntax-pair ?\e$,1r;\e(B ?\e$,1q7\e(B tbl)
+ (set-case-syntax-pair ?\e$,1rH\e(B ?\e$,1r@\e(B tbl)
+ (set-case-syntax-pair ?\e$,1rI\e(B ?\e$,1rA\e(B tbl)
+ (set-case-syntax-pair ?\e$,1rJ\e(B ?\e$,1q:\e(B tbl)
+ (set-case-syntax-pair ?\e$,1rK\e(B ?\e$,1q;\e(B tbl)
+ (set-case-syntax-pair ?\e$,1rL\e(B ?\e$,1rE\e(B tbl)
+ (set-case-syntax-pair ?\e$,1rX\e(B ?\e$,1q8\e(B tbl)
+ (set-case-syntax-pair ?\e$,1rY\e(B ?\e$,1q9\e(B tbl)
+ (set-case-syntax-pair ?\e$,1rZ\e(B ?\e$,1q<\e(B tbl)
+ (set-case-syntax-pair ?\e$,1r[\e(B ?\e$,1q=\e(B tbl)
+ (set-case-syntax-pair ?\e$,1r\\e(B ?\e$,1rS\e(B tbl)
+
+ (setq c #x0400) ; cyrillic
+ (while (<= c #x04ff)
+ (modify-category-entry (decode-char 'ucs c) ?y)
+ (and (>= c #x0400)
+ (<= c #x040f)
+ (set-case-syntax-pair
+ (decode-char 'ucs c) (decode-char 'ucs (+ c 80)) tbl))
+ (and (>= c #x0410)
+ (<= c #x042f)
+ (set-case-syntax-pair
+ (decode-char 'ucs c) (decode-char 'ucs (+ c 32)) tbl))
+ (and (zerop (% c 2))
+ (or (and (>= c #x0460) (<= c #x0480))
+ (and (>= c #x048c) (<= c #x04be))
+ (and (>= c #x04d0) (<= c #x04f4)))
+ (set-case-syntax-pair
+ (decode-char 'ucs c) (decode-char 'ucs (1+ c)) tbl))
+ (setq c (1+ c)))
+ (set-case-syntax-pair ?\e$,1*!\e(B ?\e$,1*"\e(B tbl)
+ (set-case-syntax-pair ?\e$,1*#\e(B ?\e$,1*$\e(B tbl)
+ (set-case-syntax-pair ?\e$,1*'\e(B ?\e$,1*(\e(B tbl)
+ (set-case-syntax-pair ?\e$,1*+\e(B ?\e$,1*,\e(B tbl)
+ (set-case-syntax-pair ?\e$,1*X\e(B ?\e$,1*Y\e(B tbl)
+
+ (setq c #x2000) ; general punctuation
+ (while (<= c #x200b)
+ (set-case-syntax c " " tbl)
+ (setq c (1+ c)))
+ (setq c #x2010)
+ (while (<= c #x2027)
+ (set-case-syntax c "_" tbl)
+ (setq c (1+ c)))
+ )
+
\f
;;; Setting word boundary.