XML technologies / XML / XML in a Nutshell / Cascading Style Sheets (CSS) / Font properties

(Excerpt from "XML in a Nutshell" by Elliotte Rusty Harold & W. Scott Means)

Fonts are among the most basic things designers control with CSS. Is the text italic? Is it bold? Which font and size are used? CSS provides properties to specify these important characteristics of text. In particular, you can set the following properties:

For example, this rule uses all these properties to turn the element gericht into an impressive heading:

gericht {
  font-family: Helvetica, Arial, sans-serif;
  font-size: x-large;
  font-style: italic;
  font-variant: small-caps;
  font-weight: 900;
  font-stretch: semi-expanded
}

  

 

 

 

back to top