title: How do you calculate the bouding rect for a string in Objective-C/Cocoa?
body: <p>Using Objective-C/Cocoa how do you calculate the width and height required to draw a string based on a particular font? In C#/.Net you can do it like this:</p>
  
  <pre><code>SizeF textSize = graphics.MeasureString(someString, someFont);
  </code></pre>
  
  <p>Is there something like that available in Objective-C/Cocoa?</p>