KandZ – Tuts

We like to help…!

CSS 6 💻 fonts and font properties

In CSS you can customize the font style of a web document
font-family → specifies the font family to be used for a text elements
You can add more than one by separating them with comma ','
It sets the font family to be Arial and then sans-serif
font-size → specifies the size of the font for a text element
You can use px, em, rem and % but also keywords like:
medium, x-small, small, large, x-large, smaller, larger etc
It sets the size to 16px;

font-weight → specifies the boldness of a font.
You can use keywords like normal, bold, bolder, lighter but also...
numerical values from 100 to 900
it sets the font weight to bold
font-style → specifies the style of a font
You can use normal, italic, oblique initial and inherit
initial and inherit can be used to almost all properties
It sets the style to italic

Leave a Reply