bugl
bugl
HomeLearnPatternsPathsSearch
HomeLearnPatternsPathsSearch

Loading lesson path

Learn/CSS/CSS Foundations
CSS•CSS Foundations

CSS Font Style

Flash cards

Review the key moves

1/4
Core idea

What is the main idea behind CSS Font Style?

Lesson checks

Practice each idea before moving on

Short Mimo-style checks built from this lesson's code, terms, and sequence.

1Quick choice

Which statement best captures the main point of this lesson?

2Fill blank

Complete the missing token from the example code.

___-style: normal;
3Order

Put the learning moves in the order that makes the concept easiest to apply.

- normal - The text is shown normally - italic - The text is shown in italics - oblique - The text is "leaning" (oblique is very similar to italic)
This property can have one of the following values:
The CSS font-style property specifies the font style for a text.

The CSS font-style property specifies the font style for a text..

This property can have one of the following values:

  • normal - The text is shown normally
  • italic - The text is shown in italics
  • oblique - The text is "leaning" (oblique is very similar to italic)

Example

Formatted code
p.normal {
  font-style: normal;
}
p.italic {
  font-style: italic;
}
p.oblique {
  font-style: oblique;
}

Live preview

CSS Font Weight

The CSS font-weight property specifies how thick or thin characters in text should be displayed.

This property can have one of the following values:

  • normal - This is default. Defines normal characters
  • bold - Defines thick characters
  • bolder - Defines thicker characters
  • lighter - Defines lighter characters
  • 100-900 - Defines from thin to thick characters. 400 is the same as normal, and 700 is the same as bold

Example

Formatted code
p.normal {
  font-weight: normal;
}
p.light {
  font-weight: lighter;
}
p.thick {
  font-weight: bold;
}
p.thicker {
  font-weight: 900;
}

Live preview

CSS Font Variant

The CSS font-variant property specifies whether or not a text should be displayed in a small-caps font.

In a small-caps font, all lowercase letters are converted to uppercase letters. However, the converted uppercase letters appears in a smaller font size than the original uppercase letters in the text.

Example

Formatted code
p.normal {
  font-variant: normal;
}
p.small {
  font-variant: small-caps;
}

Live preview

Previous

CSS Font Fallbacks

Next

CSS Font Size