From: tomo Date: Mon, 24 Jul 2000 12:16:09 +0000 (+0000) Subject: (decode_coding_big5): Modify for UTF-2000. X-Git-Tag: r21-2-34-utf-2000-0_17-0~34 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=6d3b0e4e2574fe4134f44195969adb5e2cfecbbc;p=chise%2Fxemacs-chise.git (decode_coding_big5): Modify for UTF-2000. --- diff --git a/src/text-coding.c b/src/text-coding.c index 94284a1..1f9167f 100644 --- a/src/text-coding.c +++ b/src/text-coding.c @@ -3537,11 +3537,20 @@ decode_coding_big5 (Lstream *decoding, const unsigned char *src, /* Previous character was first byte of Big5 char. */ if (BYTE_BIG5_TWO_BYTE_2_P (c)) { +#ifdef UTF2000 + Charset_ID b1; + unsigned char b2, b3; + DECODE_BIG5 (cpos, c, b1, b2, b3); + DECODE_ADD_UCS_CHAR (MAKE_CHAR (CHARSET_BY_LEADING_BYTE (b1), + b2 & 0x7F, b3 & 0x7F), + dst); +#else unsigned char b1, b2, b3; DECODE_BIG5 (cpos, c, b1, b2, b3); Dynarr_add (dst, b1); Dynarr_add (dst, b2); Dynarr_add (dst, b3); +#endif } else { @@ -5131,7 +5140,7 @@ char_encode_iso2022 (struct encoding_stream *str, Emchar ch, int i; Lisp_Object charset = str->iso2022.current_charset; int half = str->iso2022.current_half; - int code_point; + int code_point = -1; if (ch <= 0x7F) {