Thursday, September 3, 2009

Is Superscripting messing up your line height?


If you have ever added a registration ® or trademark ™ to your website content and then superscripted it (making it slightly smaller and pushed to the top) then you also know that it messes up your line spacing (the space between lines is taller than the others).

The fix is simple, just create a style for superscript and give it a line-height of zero:

sup {line-height: 0px;}


Its a nice little trick and is supported in (I think) every browser.


No comments:

Post a Comment