What is a CSS unit of measure?

As the title says, I want to know what exactly means a CSS unit. As in 'cm' means c enti m eter.

I do not ask what it is or how it is used!

I could not find an answer to the W3C .
The Wikipedia article already said “something”:

The name em is associated with M. Initially, the unit was obtained from the capital width "M" in this font.

My interpretation of the first sentence will be that 'em' is the pronunciation / phonetics for the letter "M".
But reading the second sentence, it seems that the "e" in "em" means something about the width of the letter "M".
So I'm still lost, what they really worth!

+33
css
Apr 05 '13 at 6:06
source share
2 answers

This is a historical definition; in modern use, it simply refers to the size of the font, and the word "em" no longer has any practical or significant meaning. In fact, the same Wikipedia article extends this evolution in its use and meaning in the next section :

One of them was traditionally defined as the capital width “M” in the current font and the size of the dot, since “M” usually used the full width of square “blocks” or “em-quads,” (also “mutton ATVs”), which are used in printing machines. However, in modern fonts, the character M is usually somewhat less than one. Moreover, as the term has expanded to include a wider variety of languages ​​and character sets, its meaning has changed; this enabled the inclusion of these fonts, fonts, and character sets that do not include capital “M,” such as the Chinese and Arabic alphabets. Thus, em usually means the dot size of the font in question, which matches the height of the metal body on which the font was applied.

In particular, in terms of CSS, “em” does not necessarily refer to the capital width M for a particular font; it is just a relative value.

If you ask about the etymology of the word "em", Wikipedia itself contains only a link to Adobe Glossary , which has something to say more about this:

The general unit of measurement in a print shop. Em is traditionally defined as the width of the uppercase M at the current face and point size. It is more accurately defined as just the current size of the point. For example, in a 12-point type, em is a distance of 12 points.

It clearly does not mention, somewhere authoritative, that this is a phonetic representation of capital M, but, given its definition of the namesake, I would not rule out such a possibility.

+34
Apr 05 '13 at 6:15
source share

In my opinion, em means only the pronunciation / phonetic letter "M". Similarly, we have ex, one ex is the x-height of the font (x-height is usually about half the size of the font).

+1
Apr 05 '13 at 8:00
source share



All Articles