International Text Display
Let’s start based on a question:
As we know only numbers can be stored in the memory, how do those numbers convert to
characters? For example, if you input a number 0xB0A1 in Chinese language, how can you get a
Chinese character “啊”. Refer to picture below.
Answer:
1. We have to construct a character set which include our needed characters. For example,
suppose I created a character set GB2312, it includes all Chinese characters. Refer to picture
below.
2. After getting the character set, we need to encode every character. In another word, we have
to mapping a number with the character. For example, mapping number “0xB0A1” with the
character “啊”. Later when you refer the number, you can get that specific character.
Now we got question II: How can we implement the mapping?
Way I(Unicode):
Define a universal mapping way. That means every character has a unique number, no matter it is
English letter or Cyrillic word. We call it Unicode. Refer to the picture below.
Advantage: Mapping is every easy.
Disadvantage: Mapping table is a little big and size of character set is huge.
评论4