CSS Web Fonts (Summary)

 The CSS @font-face Rule

Web fonts allow Web designers to use fonts that are not installed on the user's computer.


Code Sample:



Different Font Formats

  • TrueType Fonts (TTF)
  • OpenType Fonts (OTF)
  • The Web Open Font Format (WOFF)
  • The Web Open Font Format (WOFF 2.0)
  • SVG Fonts/Shapes
  • Embedded OpenType Fonts (EOT)


CSS Font Descriptors

  • font-family - Defines a name for the font

- name    

  • src - Defines the URL of the font file

- URL

  • font-stretch   -  Defines how the font should be stretched. Default is "normal

- normal

- condensed

- ultra-condensed

- extra-condensed

- semi-condensed

- expanded

- semi-expanded

- extra-expanded

- ultra-expanded

  • font-style  -  Defines how the font should be styled. Default is "normal"

- normal

- italic

- oblique

  • font-weight    -  Defines the boldness of the font. Default is "normal"

- normal

- bold

- 100

- 200

- 300

- 400

- 500

- 600

- 700

- 800

- 900

  • unicode-range    - Defines the range of UNICODE characters the font supports. Default is "U+0-10FFFF"

- unicode-range


Comments

Popular posts from this blog

CSS Text Effects (Summary)

CSS 2D Transforms (Summary)