Newspapers often style the heading font for each story according to how much space the words take up. For instance, in this spread, you can see text has been styled to fit one line:
http://www.newsdesigner.com/blog/images/feb05/best/hc6.php
And on this one, you can see different sizes for each headline according to the article size.
http://www.snd.org/snd28/worldsbest/Aripaev_files/Aripaev08.jpg
Is it possible, using some combination of CSS and jquery, to apply styling rules to a heading according to it's length? So for a short heading "A Short Heading" would have a larger font-size and letter-spacing to fit within one line. And "Slightly Longer Heading for an Article Title" would have a smaller font-size and letter-spacing to fit into two lines.
To keep this simple, assume the heading sits above a one-column fixed-width (400px) text block.