How to set font style in css

coldplay.xixi
Release: 2023-01-05 16:12:30
Original
19223 people have browsed it

How to set font style in css: 1. Use [font-family] to set the font type; 2. Use [font-size] to set the font size; 3. Use [font-variant] to set whether letters are converted to uppercase .

How to set font style in css

The operating environment of this tutorial: windows7 system, css3 version, DELL G3 computer.

How to set font style in css:

font-family: Font type (affiliation, Song Dynasty, New Roman,...)

This font type setting depends on the font library installed in the current operating system.

If the set font type can be found in the system, the font will be enabled.

If the font type is If the set font type cannot be found in the system, the default font will be used

If the font type name contains spaces, the font name needs to be enclosed in quotation marks, and Chinese characters are generally enclosed in quotation marks

font-size: Font size

Units that can be set: by percentage, by predefined keywords (smaller, larger,...), centimeters, millimeters, inches, em

font-style: Font style, generally only distinguishes between normal or slanted

font-variant: Set whether letters are converted to uppercase

Related tutorial recommendations: CSS video tutorial

The above is the detailed content of How to set font style in css. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template