Web and typographical font problems

Source: Internet
Author: User

There are already many discussions about fonts both abroad and in China, but I find that most of the content is either biased or not comprehensive enough, next I will try to summarize my views over a period of time in order to propose a more acceptable CSS font selection suggestion.

Size

The font size is always a problem for people. Is the absolute unit used or the relative unit used? Or, specifically, what unit is used? Ex? Em? Pt? Px? Percentage? Let's take a look at the descriptions in CSS 2.1 Spec:

The relative values include em, ex, and px.

Absolute size: in, cm, mm, pt, pc

Em is relative to the size specified by font-size. For example, margin: 1.2em is a margin with 1.2 characters in width. When em is used for font-size, it refers to the relative size of the inherited elements.

The percentage is relative to font-size.

Therefore, I think both em and percentage are not suitable for setting the font size. Because there are too many changing factors, changing a place may affect many other places. Ex is based on the height of the Latin letter x, which is not suitable for Chinese characters, so it is also rejected. Px is based on the resolution of the current display device. The actual size of the same px corresponds to different devices, such as the screen or paper.

Therefore, in my opinion, if the webpage should have the length of the absolute frame of reference, pt and px should be the first choice, and other lengths will change according to the percentage or em of the absolute frame of reference.

Next we will talk about the differences between web pages and printing. 99% of web pages are used to read on the screen, but the problem is that the screen resolution is much lower than that of paper, so if you directly display the font according to the size printed on the paper, it must be hard to see. For English fonts only, many subtle dots and linefeeds cannot be displayed in such a low resolution, therefore, we can only use fonts specially designed for display on the screen.

The merits and demerits of these fonts are hard to comment on. One idea is that although the serif font tends to be easier to read in paper printing than the sans-serif font, however, the font of the screen is better. So Microsoft touches Verdana as the font most suitable for webpages. I usually prefer Verdana, Arial over Times, and Georgia.

The Chinese font is different. The clear display of the Chinese font on the screen depends on the dot matrix font, or simply put, it is the simsun and simsun fonts provided by Microsoft with Windows. These fonts are designed by Dynalab, the corresponding dot matrix fonts are designed for fonts between 9pt and 12pt. Among them, the most widely used fonts are 9pt, 10.5pt and 12pt:

What about Chinese characters larger than this one? It is necessary to rely on the anti-alias (aa) technology of the operating system,

</

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.