Measurement units (Definition)

Style position and size properties use measurement units to locate objects on the screen.

Measurement units specify the units of measure of a quantity. These are typically used for length measurement but may also be used for time measurement in aural style sheet properties.

The units include the following:

UnitDescription
#A hash precedes hex color triplet values.
%A percentage of the containing element's value.
cmAbsolute measure of a centimeter.
degA value used for angular positioning of sound sources.
emA floating point value indicating a fractional portion of the length of an em-dash in the current font.
exA floating point value used to multiply the height of a small x in the current font.
HzA frequency value for aural style sheets.
inAbsolute measure of an inch.
kHzA frequency value for aural style sheets.
mmAbsolute measure of a millimeter.
msA value in milli-seconds (used for aural style durations).
pcAbsolute measure of a pica.
piAbsolute measure of a pica (possibly a misprint in some documentation).
ptAbsolute measure using a font point size.
pxAn integer value measured in pixels on the screen.
sA value in seconds (used for aural style durations).

Measurement units referring to a spatial distance on the page are sometimes called Length units.