Nothing is for sale here. Freewill tips keep the site running. Want to help? → Tip via Paypal
Font Variant
This CSS property is pretty much a one-trick pony, but it's a useful trick. With the font variant property you can set text to normal or to small-caps. Small-caps means letters that would normally be lower case letters are written as capital letters, only smaller. Regular capital letters are unchanged.
The normal value can be useful to override small caps on a case by case basis. All it does is return text to the default status.
I've often used small caps for the headings on some of my sites. Here’s how to code the font variant:
With that in your style sheet, wherever you used an h2 heading, it would be rendered in small-caps, something like this:
Who Ate My Pudding?
Depending on the font used, the difference in height between the typed capital letters and generated font variant capital letters can be greater or smaller than the example shown. For comparison, here's the same heading without the small-caps:Who Ate My Pudding?
That a wrap.