6. Control the font style
The control font style consists of four parts: control font type, font size, font style, and font width.
1. Font type
When using WORD processing software such as WORD, you often need to adjust the font display. For example, fonts such as "Arial", "Impact", and "Verdana" are mostly used by the author.
The basic format is as follows:
Font-family: font Name
If multiple font names are added to the font-family, the browser searches for installed fonts in the user's computer one by one based on the font name order, once a font matches the requirement, the webpage content is displayed in the font and the search is stopped. If the font does not match, the search continues until it is found, if all fonts in the style sheet are not installed, the browser will use its default font to display the webpage content.
Note:
When multiple fonts are specified, separate them with commas.
When the font name contains more than two separate words, use "" to enclose the font name.
When "" exists outside the style rule, use ''instead of" ".
2. Font size
The basic format is as follows:
Font-size: font size parameter
Font size value range:
Point: applicable to all browsers and operating platforms.
In Em: The size of the letter element, which is the same distance as the Point.
In Pixes: pixels can be used on all operating platforms, but the display effect may vary depending on the browser's screen resolution.
In (inches)
In cm (cm)
In mm (mm)
Unit: pc (printer font size)
In the unit of ex (x-height)
Smaller: smaller than the default size of the current text.
Larger: smaller than the default size of the current text.
Proportional relationship
Xx-small
X-small
Small
Medium
Large
X-large
Xx-large
3. Font style
The font style can only control the display of various italics.
The basic format is as follows:
Font-style: name of italic
4. Font width
The font width controls the display of bold characters. The value ranges from 100 ~ 900. The default font width of the browser is 400. In addition, the lighter and bolder parameters can be used to make the font appear finer or thicker on the original basis.
The basic format is as follows:
Font-weight: font width
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