Chinese font-family in CSS: Chinese font-family in CSS

Source: Internet
Author: User
Chinese font of font-family in CSS

Speaking of font-family in CSS, I believe many friends often use it, but I don't know how to write it when you reference Chinese fonts?
Recently, I have paid special attention to the following three types of most commonly used:

    1. 1. Direct Chinese;
    2. 2. English format;
    3. 3. Unicode code;

The preceding two forms are well understood. What does Unicode code mean? The basic definition is as follows:

Unicode (unified code, universal code, Single Code) is a character encoding used on a computer. It sets a unified and unique binary code for each character in each language to meet the requirements of cross-language and cross-platform text conversion and processing.

For more information, see Baidu encyclopedia's introduction to Unicode.
After the solution is introduced, let's talk about it again. I was reading an article written by yuber.Article《How to write Chinese fonts in CSS"Mentioned in:" simsun is not used in font-family, because some Firefox versions and opera do not support simsun writing ". I searched for related content on the Internet, most of which were excerpted from this article. I did not mention which Firefox and Opera versions do not support English writing.

In comparison, the three methods have their own advantages and disadvantages: The Chinese form is easy to remember, but it cannot be displayed normally in a system that does not support Chinese characters or a page that supports encoding; the English format is compatible with the system and encoding, but it is difficult to remember, and may have potential risks. The Unicode code is best compatible with lines, but there are also problems with hard memory.

In terms of comprehensive trade-offs, performance and security are still recommended.Unicode code. If it is not too strict, you can select the other two types.

Below we will sort out different display forms of commonly used fonts for ease of use:

Chinese name English name Unicode
Windows
* Simsun \ 5b8b \ 4f53
*Simhei Simhei \ 9ed1 \ 4f53
* Microsoft yahei \ 5fae \ 8f6f \ 96c5 \ 9ed1
Microsoft is in bold Microsoft jhenghei \ 5fae \ x8f6f \ 6b63 \ 9ed1 \ 4f53
Xin Nsimsun \ 65b0 \ 5b8b \ 4f53
New body Pmingliu \ 65b0 \ 7ec6 \ 660e \ 4f53
Fine body Mingliu \ 7ec6 \ 660e \ 4f53
Standard entity Dfkai-sb \ 6807 \ 6977 \ 4f53
Imitation Song Fangsong \ 4eff \ 5b8b
Body Kaiti \ 6977 \ 4f53
Imitation Song _ gb2312 Fangsong_gb2312 \ 4eff \ 5b8b_gb2312
_ Gb2312 Kaiti_gb2312 \ 6977 \ 4f53_gb2312
Mac OS
* stheiti light [stxihei] \ 534e \ 6587 \ 7ec6 \ 9ed1
* stheiti \ 534e \ 6587 \ 9ed1 \ 4f53
stkaiti \ 534e \ 6587 \ 6977 \ 4f53
stsong \ 534e/6587 \ 5b8b/4f53
stfangsong \ 534e \ 6587 \ 4eff \ 5b8b
Li pro lihei pro medium \ 4e3d \ 9ed1 pro
song lisong pro lisong pro light \ 4e3d \ 5b8b pro
subject body biaukai \ 6807 \ 6977 \ 4f53
Apple Lili black Apple ligothic medium \ 82f9 \ 679c \ 4e3d \ 4e2d \ 9ed1
Apple lixisong Apple lisung light \ 82f9 \ 679c \ 4e3d \ 7ec6 \ 5b8b

Marked in the above table * as a common font

Speaking of font-family in CSS, I believe many friends often use it, but I don't know how to write it when you reference Chinese fonts?
Recently, I have paid special attention to the following three types of most commonly used:

    1. 1. Direct Chinese;
    2. 2. English format;
    3. 3. Unicode code;

The preceding two forms are well understood. What does Unicode code mean? The basic definition is as follows:

Unicode (unified code, universal code, Single Code) is a character encoding used on a computer. It sets a unified and unique binary code for each character in each language to meet the requirements of cross-language and cross-platform text conversion and processing.

For more information, see Baidu encyclopedia's introduction to Unicode.
After the solution is introduced, let's talk about it again. I was reading an article titled 《How to write Chinese fonts in CSS"Mentioned in:" simsun is not used in font-family, because some Firefox versions and opera do not support simsun writing ". I searched for related content on the Internet, most of which were excerpted from this article. I did not mention which Firefox and Opera versions do not support English writing.

In comparison, the three methods have their own advantages and disadvantages: The Chinese form is easy to remember, but it cannot be displayed normally in a system that does not support Chinese characters or a page that supports encoding; the English format is compatible with the system and encoding, but it is difficult to remember, and may have potential risks. The Unicode code is best compatible with lines, but there are also problems with hard memory.

In terms of comprehensive trade-offs, performance and security are still recommended.Unicode code. If it is not too strict, you can select the other two types.

Below we will sort out different display forms of commonly used fonts for ease of use:

Chinese name English name Unicode
Windows
* Simsun \ 5b8b \ 4f53
*Simhei Simhei \ 9ed1 \ 4f53
* Microsoft yahei \ 5fae \ 8f6f \ 96c5 \ 9ed1
Microsoft is in bold Microsoft jhenghei \ 5fae \ x8f6f \ 6b63 \ 9ed1 \ 4f53
Xin Nsimsun \ 65b0 \ 5b8b \ 4f53
New body Pmingliu \ 65b0 \ 7ec6 \ 660e \ 4f53
Fine body Mingliu \ 7ec6 \ 660e \ 4f53
Standard entity Dfkai-sb \ 6807 \ 6977 \ 4f53
Imitation Song Fangsong \ 4eff \ 5b8b
Body Kaiti \ 6977 \ 4f53
Imitation Song _ gb2312 Fangsong_gb2312 \ 4eff \ 5b8b_gb2312
_ Gb2312 Kaiti_gb2312 \ 6977 \ 4f53_gb2312
Mac OS
* stheiti light [stxihei] \ 534e \ 6587 \ 7ec6 \ 9ed1
* stheiti \ 534e \ 6587 \ 9ed1 \ 4f53
stkaiti \ 534e \ 6587 \ 6977 \ 4f53
stsong \ 534e/6587 \ 5b8b/4f53
stfangsong \ 534e \ 6587 \ 4eff \ 5b8b
Li pro lihei pro medium \ 4e3d \ 9ed1 pro
song lisong pro lisong pro light \ 4e3d \ 5b8b pro
subject body biaukai \ 6807 \ 6977 \ 4f53
Apple Lili black Apple ligothic medium \ 82f9 \ 679c \ 4e3d \ 4e2d \ 9ed1
Apple lixisong Apple lisung light \ 82f9 \ 679c \ 4e3d \ 7ec6 \ 5b8b

in the above table, * is a common font.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.