Mercurial > emacs
comparison admin/charsets/mapconv @ 89815:59bbae51ad73
Add code for handling KANJI-DATABASE format.
author | Kenichi Handa <handa@m17n.org> |
---|---|
date | Thu, 12 Feb 2004 07:38:43 +0000 |
parents | b7afe7c870d3 |
children | 44f20ef7b2c5 |
comparison
equal
deleted
inserted
replaced
89814:bd285ab281c3 | 89815:59bbae51ad73 |
---|---|
49 SOURCE="http://www.unicode.org/Public/MAPPINGS/.../${BASE}";; | 49 SOURCE="http://www.unicode.org/Public/MAPPINGS/.../${BASE}";; |
50 YASUOKA) | 50 YASUOKA) |
51 SOURCE="http://kanji.zinbun.kyoto-u.ac.jp/~yasuoka/.../${BASE}";; | 51 SOURCE="http://kanji.zinbun.kyoto-u.ac.jp/~yasuoka/.../${BASE}";; |
52 MICROSOFT) | 52 MICROSOFT) |
53 SOURCE="http://www.microsoft.com/globaldev/reference/oem/${BASE}";; | 53 SOURCE="http://www.microsoft.com/globaldev/reference/oem/${BASE}";; |
54 KANJI-DATABASE) | |
55 SOURCE="data at http://sourceforge.net/cvs/?group_id=26261";; | |
54 *) | 56 *) |
55 echo "Unknown file type: $3"; | 57 echo "Unknown file type: $3"; |
56 exit 1;; | 58 exit 1;; |
57 esac | 59 esac |
58 | 60 |
125 # Source format is: | 127 # Source format is: |
126 # XX = U+YYYY | 128 # XX = U+YYYY |
127 sed -n -e "$2 p" < $1 \ | 129 sed -n -e "$2 p" < $1 \ |
128 | sed -e 's/\([0-9A-F]*\).*U+\([0-9A-F]*\).*/0x\1 0x\2/' \ | 130 | sed -e 's/\([0-9A-F]*\).*U+\([0-9A-F]*\).*/0x\1 0x\2/' \ |
129 | sort | ${AWKPROG} | 131 | sort | ${AWKPROG} |
132 elif [ "$3" == "KANJI-DATABASE" ] ; then | |
133 # Source format is: | |
134 # C?-XXXX U+YYYYY ..... | |
135 sed -n -e "$2 p" < $1 \ | |
136 | sed -e 's/...\(....\) U+\([0-9A-F]*\).*/0x\1 0x\2/' \ | |
137 | sort | ${AWKPROG} | |
130 else | 138 else |
131 echo "Invalid arguments" | 139 echo "Invalid arguments" |
132 exit 1 | 140 exit 1 |
133 fi | 141 fi |