title: Resize NSPopupButton to its selected title
body: <p>I've a NSPopupButton and I want it so resize itself to fit the selected title.</p>
  
  <p>[NSPopupButton sizeToFit] doesn't fit my needs because the popup is resized to the largest title item not to the current selected one</p>
  
  <p>I've tried in may ways without success the closer is </p>
  
  <pre><code>#define ARROW_WIDTH 20
  NSDictionary *displayAttributes = [NSDictionary dictionaryWithObjectsAndKeys:[popup font], NSFontAttributeName, nil];
  NSSize titleSize = [popup.titleOfSelectedItem sizeWithAttributes:displayAttributes] + ARROW_WIDTH;
  </code></pre>
  
  <p>But the constant value ARROW_WIDTH is a really dirty and error prone solution.</p>
  
  <p>TextWrangler encoding combo on status bar works like I need</p>