Universal Character Set - Encoding Forms of The Universal Character Set

Encoding Forms of The Universal Character Set

ISO 10646 defines several character encoding forms for the Universal Character Set. The simplest, UCS-2, uses a single code value (defined as one or more numbers representing a code point) between 0 and 65,535 for each character, and allows exactly two bytes (one 16-bit word) to represent that value. UCS-2 thereby permits a binary representation of every code point in the BMP, as long as the code point represents a character. UCS-2 cannot represent code points outside the BMP. Occasionally, articles about Unicode will mistakenly refer to UCS-2 as "UCS-16". UCS-16 does not exist; the authors who make this error usually intend to refer to UCS-2 or to UTF-16.

The first amendment to the original edition of the UCS defined UTF-16, an extension of UCS-2, to represent code points outside the BMP. A range of code points in the S (Special) Zone of the BMP remains unassigned to characters. UCS-2 disallows use of code values for these code points, but UTF-16 allows their use in pairs. Unicode also adopted UTF-16, but in Unicode terminology, the high-half zone elements become "high surrogates" and the low-half zone elements become "low surrogates".

Another encoding, UCS-4, uses a single code value between 0 and (theoretically) hexadecimal 7FFFFFFF for each character (although the UCS stops at 10FFFF and ISO/IEC 10646 has stated that all future assignments of characters will also take place in that range). UCS-4 allows representation of each value as exactly four bytes (one 32-bit word). UCS-4 thereby permits a binary representation of every code point in the UCS, including those outside the BMP. As in UCS-2, every encoded character has a fixed length in bytes, which makes it simple to manipulate, but of course it requires twice as much storage as UCS-2.

Currently, the dominant UCS encoding is UTF-8, which is a variable-width encoding designed for backward compatibility with ASCII, and for avoiding the complications of endianness and byte-order marks in UTF-16 and UTF-32. More than half of all Web pages are encoded in UTF-8. The Internet Engineering Task Force (IETF) requires all Internet protocols to identify the encoding used for character data, and the supported character encodings must include UTF-8. The Internet Mail Consortium (IMC) recommends that all e-mail programs be able to display and create mail using UTF-8. It is also increasingly being used as the default character encoding in operating systems, programming languages, APIs, and software applications.

See also Comparison of Unicode encodings.

Read more about this topic:  Universal Character Set

Famous quotes containing the words forms, universal, character and/or set:

    A strange effect of marriage, such as the nineteenth century has made it! The boredom of married life inevitably destroys love, when love has preceded marriage. And yet, as a philosopher has observed, it speedily brings about, among people who are rich enough not to have to work, an intense boredom with all quiet forms of enjoyment. And it is only dried up hearts, among women, that it does not predispose to love.
    Stendhal [Marie Henri Beyle] (1783–1842)

    The universal principle of etymology in all languages: words are carried over from bodies and from the properties of bodies to express the things of the mind and spirit. The order of ideas must follow the order of things.
    Giambattista Vico (1688–1744)

    Foolish, whenever you take the meanness and formality of that thing you do, instead of converting it into the obedient spiracle of your character and aims.
    Ralph Waldo Emerson (1803–1882)

    The monotonous dead clog me up and there is only
    black done in black that oozes from the strongbox.
    I must disembowel it and then set the heart, the legs,
    of two who were one upon a large woodpile
    and ignite, as I was once ignited, and let it whirl
    into flame....
    Anne Sexton (1928–1974)