Mercurial > emacs
changeset 66059:17f02a9e1c99
(ccl-encode-unicode-font): Lookup
utf-subst-table-for-encode, not ucs-mule-cjk-to-unicode. Handle
the case that ucs-mule-to-mule-unicode translates a character to
ASCII (usually for IPA characters).
author | Kenichi Handa <handa@m17n.org> |
---|---|
date | Thu, 13 Oct 2005 02:24:23 +0000 |
parents | 702baea25eb3 |
children | 65f0f700ffb8 |
files | lisp/international/fontset.el |
diffstat | 1 files changed, 29 insertions(+), 26 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/international/fontset.el Wed Oct 12 23:06:20 2005 +0000 +++ b/lisp/international/fontset.el Thu Oct 13 02:24:23 2005 +0000 @@ -173,39 +173,42 @@ ((if (r2 >= 0) ;; This is a 2D charset. (r1 = ((r1 << 7) | r2))) - (lookup-character ucs-mule-cjk-to-unicode r0 r1) + (lookup-character utf-subst-table-for-encode r0 r1) (if r7 ;; We got it! ((r1 = (r0 >> 8)) (r2 = (r0 & #xFF))) ;; Look for a translation for non-ASCII chars. ((translate-character ucs-mule-to-mule-unicode r0 r1) - (if (r0 == ,(charset-id 'latin-iso8859-1)) - ((r2 = (r1 + 128)) + (if (r0 == ,(charset-id 'ascii)) + ((r2 = r1) (r1 = 0)) - ((r2 = (r1 & #x7F)) - (r1 >>= 7) - (if (r0 == ,(charset-id 'mule-unicode-0100-24ff)) - ((r1 *= 96) - (r1 += r2) - (r1 += ,(- #x100 (* 32 96) 32)) - (r1 >8= 0) - (r2 = r7)) - (if (r0 == ,(charset-id 'mule-unicode-2500-33ff)) - ((r1 *= 96) - (r1 += r2) - (r1 += ,(- #x2500 (* 32 96) 32)) - (r1 >8= 0) - (r2 = r7)) - (if (r0 == ,(charset-id 'mule-unicode-e000-ffff)) - ((r1 *= 96) - (r1 += r2) - (r1 += ,(- #xe000 (* 32 96) 32)) - (r1 >8= 0) - (r2 = r7)) - ;; No way, use the glyph for U+FFFD. - ((r1 = #xFF) - (r2 = #xFD))))))))))))) + ((if (r0 == ,(charset-id 'latin-iso8859-1)) + ((r2 = (r1 + 128)) + (r1 = 0)) + ((r2 = (r1 & #x7F)) + (r1 >>= 7) + (if (r0 == ,(charset-id 'mule-unicode-0100-24ff)) + ((r1 *= 96) + (r1 += r2) + (r1 += ,(- #x100 (* 32 96) 32)) + (r1 >8= 0) + (r2 = r7)) + (if (r0 == ,(charset-id 'mule-unicode-2500-33ff)) + ((r1 *= 96) + (r1 += r2) + (r1 += ,(- #x2500 (* 32 96) 32)) + (r1 >8= 0) + (r2 = r7)) + (if (r0 == ,(charset-id 'mule-unicode-e000-ffff)) + ((r1 *= 96) + (r1 += r2) + (r1 += ,(- #xe000 (* 32 96) 32)) + (r1 >8= 0) + (r2 = r7)) + ;; No way, use the glyph for U+FFFD. + ((r1 = #xFF) + (r2 = #xFD))))))))))))))) "Encode characters for display with iso10646 font. Translate through the translation-hash-table named `ucs-mule-cjk-to-unicode' and the translation-table named