PDA

View Full Version : setting a line height..


gigiloumill
06-08-2011, 01:21 PM
Guys, does anyone know how to set the line height between an H1 and a P? Thanks

domedia
06-08-2011, 01:47 PM
Line height is inside an element, not between :)

If you want to set the space between them use CSS margin.

DWcourse
06-08-2011, 05:48 PM
Line height is inside an element, not between :)

If you want to set the space between them use CSS margin.

Just to expand a bit on that a bit. Line-height is basically what print designers refer to as leading, the distance between the baselines of successive lines of type. So the line height for an html object <body, div, p, h1, h2, etc) would govern the spacing between lines of type within that object.

domedia
06-08-2011, 06:17 PM
humm humm.. 'baselines of successive lines of types' .. For the non typography guys like me, can you elaborate :) I just to make sure I fully know what it is.

DWcourse
06-08-2011, 06:32 PM
I'll probably get in over my head. I always hated specifying type for a typesetter (and, yes, I'm that old). Anyway, the baseline is like the blue lines we had on our writing paper as kids. It's the line the type sits on – the bottom of characters like m and n (some letters like g and j have descenders that drop below the baseline). So leading and CSS line-height is the distance between the baseline of one line of type and the baseline of the line of type below it.

A graphic is probably easier, i've attached one.