diff --git a/lib/libi18n/ucs2.c b/lib/libi18n/ucs2.c index 0ff4266079ff..b551254b742b 100644 --- a/lib/libi18n/ucs2.c +++ b/lib/libi18n/ucs2.c @@ -167,7 +167,7 @@ CS_VIET_TCVN, CS_VIET_VNI, /* 0x60 - 0x6F*/ -CS_UNKNOWN, +CS_T61, CS_UNKNOWN, CS_UNKNOWN, CS_UNKNOWN, @@ -401,6 +401,14 @@ PRIVATE uint16 DingbatsToTbl[] = { #include "macdingb.ut" }; /*--------------------------------------------------------------------------*/ +/* T61 Stuff */ +PRIVATE uint16 T61FromTbl[] = { +#include "t61.uf" +}; +PRIVATE uint16 T61ToTbl[] = { +#include "t61.ut" +}; +/*--------------------------------------------------------------------------*/ /* Thai */ PRIVATE uint16 TIS620FromTbl[] = { #include "cp874.uf" /* use cp874 untill we have real TIS 620 table */ @@ -492,6 +500,8 @@ PRIVATE uTable* LoadToUCS2Table(uint16 csid) case CS_TIS620: return (uTable*) TIS620ToTbl; + case CS_T61: + return (uTable*) T61ToTbl; /* Other Stuff */ default: XP_ASSERT(TRUE); @@ -583,6 +593,8 @@ PRIVATE uTable* LoadFromUCS2Table(uint16 csid) case CS_TIS620: return (uTable*) TIS620FromTbl; + case CS_T61: + return (uTable*) T61FromTbl; /* Other Stuff */ default: XP_ASSERT(TRUE); @@ -2006,7 +2018,6 @@ PUBLIC uint32 INTL_TextToUnicode( XP_ASSERT(i!=num); #endif *ustr= NOMAPPING; - scanlen=1; } } *ustr = (INTL_Unicode) 0; diff --git a/lib/libi18n/ugendata.c b/lib/libi18n/ugendata.c index 0013334d0a5d..e365b1398cf0 100644 --- a/lib/libi18n/ugendata.c +++ b/lib/libi18n/ugendata.c @@ -90,6 +90,15 @@ PRIVATE int16 sjisShiftT[] = { ShiftCell(u2BytesChar, 2, 0x81, 0x9F, 0x81, 0x40, 0x9F, 0xFC), ShiftCell(u2BytesChar, 2, 0xE0, 0xFC, 0xE0, 0x40, 0xFC, 0xFC) }; +/*----------------------------------------------------------------------------------- + ShiftTable for t61 encoding +-----------------------------------------------------------------------------------*/ +PRIVATE int16 t61ShiftT[] = { + 3, uMultibytesCharset, + ShiftCell(u1ByteChar, 1, 0x00, 0xBF, 0x00, 0x00, 0x00, 0xBF), + ShiftCell(u1ByteChar, 1, 0xD0, 0xFF, 0x00, 0xD0, 0x00, 0xFF), + ShiftCell(u2BytesChar, 2, 0xC0, 0xCF, 0xC0, 0x41, 0xCF, 0x7A) +}; /*----------------------------------------------------------------------------------- ShiftTable for JIS0212 in EUCJP encoding -----------------------------------------------------------------------------------*/ @@ -257,7 +266,7 @@ sbShiftT, sbShiftT, /* 0x60-0x67 */ -0, +t61ShiftT, 0, 0, 0, @@ -422,7 +431,7 @@ sbShiftT, sbShiftT, /* 0x60-0x67 */ -0, +t61ShiftT, 0, 0, 0, diff --git a/lib/libi18n/umap.c b/lib/libi18n/umap.c index 2c856301b801..2d204d60430b 100644 --- a/lib/libi18n/umap.c +++ b/lib/libi18n/umap.c @@ -127,6 +127,7 @@ MODULE_PRIVATE XP_Bool uMapCode(uTable *uT, uint16 in, uint16* out) XP_Bool done = FALSE; uint16 itemOfList = uT->itemOfList; uint16 i; + *out = NOMAPPING; for(i=0;i