(defvar chise-wiki-displayed-features nil)
+(defvar est-coded-charset-priority-list
+ '(; =ucs
+ =cns11643-1 =cns11643-2 =cns11643-3
+ =cns11643-4 =cns11643-5 =cns11643-6 =cns11643-7
+ =gb2312 =gb12345
+ =jis-x0208 =jis-x0208@1990
+ =jis-x0213-2
+ =jis-x0212
+ =adobe-japan1
+ =cbeta =jef-china3
+ =jis-x0213-1@2000 =jis-x0213-1@2004
+ =jis-x0208@1983 =jis-x0208@1978
+ =zinbun-oracle =>zinbun-oracle
+ =daikanwa
+ =gt =gt-k
+ =>>>adobe-japan1
+ =>>>jis-x0208 =>>>jis-x0213-1 =>>>jis-x0213-2
+ =>>jis-x0208 =>>jis-x0213-1 =>>jis-x0213-2
+ =>>adobe-japan1
+ =+>jis-x0208 =+>jis-x0213-1 =+>jis-x0213-2
+ =+>jis-x0208@1978
+ =+>adobe-japan1
+ =>jis-x0208 =>jis-x0213-1
+ =>>gt
+ =>ucs@iso =>ucs@unicode
+ =>ucs@jis =>ucs@cns =>ucs@ks
+ =>>ucs@iso =>>ucs@unicode
+ =>>ucs@jis =>>ucs@cns =>>ucs@ks
+ =>>>ucs@iso =>>>ucs@unicode
+ =>>>ucs@jis =>>>ucs@cns =>>>ucs@ks
+ =ruimoku-v6
+ =big5
+ =big5-cdp
+ =ucs-itaiji-002))
+
(defun decode-uri-string (string &optional coding-system)
(if (> (length string) 0)
(let ((i 0)
(format "%%%02X" byte))
(encode-coding-string (char-to-string object) 'utf-8-mcs-er)
"")
- (let ((ccs-list '(; =ucs
- =cns11643-1 =cns11643-2 =cns11643-3
- =cns11643-4 =cns11643-5 =cns11643-6 =cns11643-7
- =gb2312 =gb12345
- =jis-x0208 =jis-x0208@1990
- =jis-x0213-2
- =jis-x0212
- =adobe-japan1
- =cbeta =jef-china3
- =jis-x0213-1@2000 =jis-x0213-1@2004
- =jis-x0208@1983 =jis-x0208@1978
- =zinbun-oracle =>zinbun-oracle
- =daikanwa
- =gt =gt-k
- =>>>adobe-japan1
- =>>>jis-x0208 =>>>jis-x0213-1 =>>>jis-x0213-2
- =>>jis-x0208 =>>jis-x0213-1 =>>jis-x0213-2
- =>>adobe-japan1
- =+>jis-x0208 =+>jis-x0213-1 =+>jis-x0213-2
- =+>jis-x0208@1978
- =+>adobe-japan1
- =>jis-x0208 =>jis-x0213-1
- =>>gt
- =>ucs@iso =>ucs@unicode
- =>ucs@jis =>ucs@cns =>ucs@ks
- =>>ucs@iso =>>ucs@unicode
- =>>ucs@jis =>>ucs@cns =>>ucs@ks
- =>>>ucs@iso =>>>ucs@unicode
- =>>>ucs@jis =>>>ucs@cns =>>>ucs@ks
- =ruimoku-v6
- =big5
- =big5-cdp))
+ (let ((ccs-list est-coded-charset-priority-list)
ccs ret)
(while (and ccs-list
(setq ccs (pop ccs-list))
t 'literal))
(goto-char (point-min))
+ (while (re-search-forward "&\\(o-\\|G-\\|g2-\\|R-\\)?U-i\\([0-9]+\\)\\+\\([0-9A-F]+\\);" nil t)
+ (setq plane (string-to-int (match-string 2))
+ code (string-to-int (match-string 3) 16))
+ (replace-match
+ (format "<img alt=\"u%04x-itaiji-%03d\" src=\"http://glyphwiki.org/glyph/u%04x-itaiji-%03d.100px.png\"
+style=\"vertical-align:middle; width: 48px; height: 48px\">"
+ code
+ plane
+ code
+ plane
+ www-format-char-img-style)
+ t 'literal))
+
+ (goto-char (point-min))
(while (re-search-forward "&\\(G-\\|R-\\|g2-\\)?GT-\\([0-9]+\\);" nil t)
(setq code (string-to-int (match-string 2)))
(replace-match
(=+>jis-x0208@1983 "j83-" 4 x nil)
(=cbeta "cb" 5 d nil)
(=>>daikanwa "dkw-" 5 d nil)
+ (=ucs-var-001 "u" 4 x "-var-001")
+ (=ucs-var-002 "u" 4 x "-var-002")
+ (=ucs-var-003 "u" 4 x "-var-003")
+ (=ucs-itaiji-002 "u" 4 x "-itaiji-002")
+ (=ucs-itaiji-084 "u" 4 x "-itaiji-084")
+ (=big5-cdp-var-3 "cdp-" 4 x "-var-3")
+ (=big5-cdp-var-5 "cdp-" 4 x "-var-5")
))
(defun char-GlyphWiki-id (char)