Hacker News new | ask | show | jobs
by thundermuffin 1482 days ago
You can still have this problem apply even if you are using flex and aligning items to the center.

If a font has some weird characteristic about it (for instance, the font itself has built in whitespace at the bottom or top of letters), you will not be able to center it vertically no matter what CSS magic you try to do except for doing some kind of translation on it; that translation doesn't have to be pixel-based either, but it will 100% have to happen until hopefully when the leading-trim property that saadat mentioned is widely available.