Jumat, 20 April 2012

How to calculate descender height in javascript?

My css has defined the font-family to cascade depending on what fonts are available: .myfont { text-transform: uppercase; font-family: Calibri, Arial, sans-serif; padding: 2em; background-color: red; } and, depending on what font is rendered, I would like to adjust the padding to appropriately center the all-caps text in the beautiful red background. Is

0 comments:

Posting Komentar