copyright © CSSPG, lud October 04 1999


 for practical use of CSS

Font declarations

this document is located at...
<URI:http://css.nu/examples/font-size.html>

* Absolute size keywords *

The CSS1 Recommendation provides multiple methods for suggesting font sizes. Not all variations are supported equally by current implementations. These tests provide a means of gauging the rendering results of these suggestions. Selective fonts used are those which are available on the PC and iMac available to me. YMMV if the fonts are not available on your system.

* Absolute size keywords *

font-family: cursive
xx-small
x-small
small
medium
large
x-large
xx-large

font-family: fantasy
xx-small
x-small
small
medium
large
x-large
xx-large

font-family: monospace
xx-small
x-small
small
medium
large
x-large
xx-large

font-family: sans-serif
xx-small
x-small
small
medium
large
x-large
xx-large

font-family: serif
xx-small
x-small
small
medium
large
x-large
xx-large

* Relative size keywords *

font-family: cursive
smaller
larger

font-family: fantasy
smaller
larger

font-family: monospace
smaller
larger

font-family: sans-serif
smaller
larger

font-family: serif
smaller
larger

* Length *

absolute units

font-family: monospace
5mm
10mm

font-family: sans-serif
.5cm
1cm

font-family: serif
20px
50px

font-family: cursive
.8pc
1pc

font-family: fantasy
8pt
12pt

font-family: monospace
.25in
.5in

relative units

font-family: serif
1em
2em

font-family: monospace
1ex
2ex

* Percentage *

font-family: serif
120%
200%

font-family: sans-serif
90%
75%


CSS Pointers Navigation
Index · Browser Bugs · Books · Tools · DHTML · XSL & DSSSL
Main Site Navigation
Index · Articles · Examples · Experiments · FAQ · Markup · Styles · Who is?
CSSPG ~ Sue ~ Roland
Validate markup Check CSS