View Full Version : Font size with two values

Feb 7th, 2007, 02:06 PM
Hello everybody,

today I encountered to rather peculiar CSS declaration:
body {font:76%/120% Arial, Helvetica, sans-serif;}

First property (76%) stands for font-size and second one (120%) seems to affect on font/line height.

Is it really that I've been doing these things last decade for serious money and never have encountered declaration like above?

Is that declared somewhere as a CSS standard? I didn't found anything with quick browsing?

I'm still completely confused and amazed..

Feb 7th, 2007, 02:31 PM
Strange I have never seen it either, infact when I tested the script it didnt actually do anything :S

Feb 7th, 2007, 02:41 PM
I thought you used that declaration to define the font-size of the first font in your list, and the second size for the second font in your list? Maybe I'm making that up?

Feb 7th, 2007, 03:17 PM
That feature of defining multiple declarations for multiple fonts is somewhere in "barrel of empty wishes", I think.

It worked for me both in IE and FF. And there are no scripts / alternate hacks modifying functionality.

Feb 7th, 2007, 04:36 PM
It's CSS shorthand. i.e.,

font-weight: bold;
font-size: 76%;
line-height: 1.5;
font-family: verdana, arial, sans-serif;

can be written as

font: bold 76%/1.5 verdana, arial, sans-serif;

See this link for more info:


Feb 7th, 2007, 04:54 PM
It's a regular part of the W3C specs: W3C CSS 2.1 - font property (http://www.w3.org/TR/CSS21/fonts.html#propdef-font).

Feb 8th, 2007, 12:44 AM
Well, today I've learned something new..

..it's a good goal for every day life \o/