From: tomo Date: Tue, 26 Feb 2002 11:15:33 +0000 (+0000) Subject: (file-name-char-attribute-name) New function. X-Git-Tag: r21-2-44-lazy-n7c~74 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=33675e2603a277ca9546c7f08245d584ced1d0ba;p=chise%2Fxemacs-chise.git- (file-name-char-attribute-name) New function. Use `file-name-char-attribute-name' to get character attribute names. --- diff --git a/lisp/utf-2000/make-cdbs.el b/lisp/utf-2000/make-cdbs.el index 2ecc050..93f46c7 100644 --- a/lisp/utf-2000/make-cdbs.el +++ b/lisp/utf-2000/make-cdbs.el @@ -34,8 +34,27 @@ (dolist (ccs (charset-list)) (save-charset-mapping-table ccs))) +(defun file-name-char-attribute-name (filename) + (let ((i 0) + (base 0) + (len (length filename)) + chr dest) + (while (< i len) + (if (eq (setq chr (aref filename i)) ?%) + (setq dest (concat dest + (substring filename base i) + (char-to-string + (int-char + (string-to-int + (substring filename (1+ i) (+ i 3)) 16)))) + i (+ i 3) + base i) + (setq i (1+ i)))) + (concat dest (substring filename base len)))) + (mapcar (lambda (file) - (reset-char-attribute-table (intern file))) + (reset-char-attribute-table + (intern (file-name-char-attribute-name file)))) (directory-files (expand-file-name "system-char-id" system-char-database-directory)