title: How do I get the size of a string truncated by UILabel?
body: <p>I need to find the on screen size (CGSize) of a string that will be drawn in a UILabel. I know that I can use:</p>
  
  <pre><code>-(CGSize)sizeWithFont:(UIFont *)font constrainedToSize:(CGSize)size lineBreakMode:(UILineBreakMode)lineBreakMode
  </code></pre>
  
  <p>To find the size that a string will be, however, it does not take into account the maximum number of lines that UILabel lets you specify.</p>
  
  <p>To rephrase if my UILabel has numberOfLines set to 2, and it receives a long string that gets truncated, how do I find the size (CGSize) of the string that is going to be drawn by the UILabel?</p>
  
  <p>Thanks!</p>