title: CoreAnimation setFrameCenterRotation Doesn't Animate Properly
body: <p>I'm having a bit of trouble with getting CoreAnimation to rotate an NSView about its center point. All I want to do is rotate an NSView while keeping its center point static so that the object appears to rotate in place.</p>
  
  <p>The way I chose to do this involves the use of the <code>animator</code> property in NSView. The code is as follows:</p>
  
  <pre><code>[NSAnimationContext beginGrouping];
  [[NSAnimationContext currentContext] setDuration:1.0];
  
  [[view animator] setFrameCenterRotation:45.0];
  
  [NSAnimationContext endGrouping];
  </code></pre>
  
  <p>Where <code>view</code> is the NSView that I am trying to rotate. The result of this code makes the object abruptly shift to the right somewhat then does the rotation. The final result is correct, but the animation doesn't look right because of the movement it makes in the beginning. I'm assuming that this is because the way that <code>setFrameCenterRotation:</code> works is that it shifts the frame origin to the view's center point first, then makes the rotation.</p>
  
  <p>What am I doing wrong here? Is there a better way, perhaps, to rotate an NSView about the center? Thanks a lot!</p>