|
From: | Alex Schroeder |
Subject: | [emacs-bidi] bidi tables for unicode chars |
Date: | Fri, 09 Nov 2001 19:44:28 +0100 |
User-agent: | Gnus/5.090004 (Oort Gnus v0.04) Emacs/21.1 (i686-pc-linux-gnu) |
I have a table like the following for all Unicode characters. '((?\x0000 . bidi-category-bn) (?\x0001 . bidi-category-bn) (?\x0002 . bidi-category-bn) (?\x0003 . bidi-category-bn) (?\x0004 . bidi-category-bn) (?\x0005 . bidi-category-bn) ... This is the result of parsing the UnicodeData.txt file from the Unicode site. The car of his table is a unicode character. What I want to do is this: (mapcar (lambda (entry) (let ((char (car entry)) (cat (cdr entry))) (modify-category-entry char cat table t)))) Obviously CHAR is not good enough; I somehow need to get the correct char in the unicode charsets. Can I use this: (cond ((and (char >= ?\x0100) (char <= ?\x24ff)) (make-char 'mule-unicode-0100-24ff (- char ?\x0100))) ((and (char >= ?\x2500) (char <= ?\x33ff)) (make-char 'mule-unicode-2500-33ff (- char ?\x2500))) ((and (char >= ?\xe000) (char <= ?\xffff)) (make-char 'mule-unicode-e000-ffff (- char ?\xe000))) ((char <= ?\x0100) (make-char 'latin-iso8859-1 char))) -- http://www.emacswiki.org/
[Prev in Thread] | Current Thread | [Next in Thread] |