RE: ISO 8859-11 (Thai) cross-mapping table

From: Marco Cimarosti (marco.cimarosti@essetre.it)
Date: Tue Oct 08 2002 - 05:54:02 EDT

  • Next message: John Cowan: "Re: ISO 8859-11 (Thai) cross-mapping table"

    Kenneth Whistler wrote:
    > Elliotte Harold asked:
    >
    > > The Unicode data files at
    > > http://www.unicode.org/Public/MAPPINGS/ISO8859/ do not
    > include a mapping
    > > for ISO-8859-11, Thai. Is there any particular reason for this?
    >
    > Just that nobody got around to submitting and posting one.
    >
    > Since there was a lot of discussion about this over the weekend,
    > I took it upon myself to create and post one in the same format
    > as the other ISO8859 tables.

    Thanks!

    Talking about the format of mapping tables, I always wondered why not using
    ranges. In the case of ISO 8859-11, the table would become as compact as
    three lines:

            0x00..0xA0 0x0000..0x00A0 # NULL..NO-BREAK SPACE
            0xA1..0xDA 0x0E01..0x0E3A # THAI CHARACTER KO KAI..THAI
    CHARACTER PHINTHU
            0xDF..0xFB 0x0E3F..0x0E5B # THAI CURRENCY SYMBOL
    BAHT..THAI CHARACTER KHOMUT

    This is probably what most APIs already do at the binary level, where a
    bidirectional ISO 8859-11 table can be as compact as 12 bytes:

            struct MapSbcs
            {
                unsigned char SbcsChar;
                unsigned short BmpChar;
                unsigned char Count;
            };
            struct MapSbcs Map8859_11 [] =
            {
               { 0x00, 0x0000, 0xA0 },
               { 0xA1, 0x0E01, 0x39 },
               { 0xDF, 0x0E3F, 0x1C }
            };

    _ Marco



    This archive was generated by hypermail 2.1.5 : Tue Oct 08 2002 - 06:41:48 EDT