title: How to truncate an NSString based on the graphical width?
body: <p>In UILabel there's functionality to truncate labels using different truncation techniques (UILineBreakMode). In NSString UIKit Additions there is a similar functionality for drawing strings.</p>
  
  <p>However, I found no way to access the actual truncated string. Is there any other way to get a truncated string based on the (graphical) width for a given font?</p>
  
  <p>I'd like to have a category on NSString with this method:</p>
  
  <pre><code>-(NSString*)stringByTruncatingStringWithFont:(UIFont *)font forWidth:(CGFloat)width lineBreakMode:(UILineBreakMode)lineBreakMode
  </code></pre>