cocoa - Animated rotation of NSView contents -


I'm trying to rotate the contents of NSView ( NSButton In-Place (from IE center I want to convert - to | / />). This can be done with setFrameCenterRotation: รข ?? | However, I am trying to animate it, and

  [[MyView animator] setFrameCenterRotation: 90];   

First cause the control to jump right, and then rotate at the bottom of the bottom left corner (0,0).

Some people have suggested setting before anchorpoint :

  [[myview layer] setAnchorPoint: NSMakePoint (0.5, 0.5)] ;   

But for some reasons the animation cancels it and it gets reset (0, 0).

So, did anybody have thought that these- one NSView

If you add, this does not happen to control the interface builder and rotate it using its IBOutlet. You do not have to use the "setAnchorPoint:" method; The "SetFrameCenterRotation:" method will work itself, though the same thing happened to me when I tried to rotate NSBetton, I have a subview in NSCL. See a NSView the Anssisel subclass ControlView (below the solution had to be as a Sbwu) and NSButton require rotation as a Updrishy the new NSView.

  - (minus) drawWithFrame :( Ansarakt) Selfrem Inwu: (Ansviuui *) Kantrolwus {if (! [Bitianakkek look back view]) {// Bitiankakbakwu my NSView which Ansbittn "Bitian- smallpox is holding "[Bitian Chekbak set ephraim: Ansaraktfarmsigret (Sijiarkemkek (9 Selfremkorgin. 8 + 8, 28, 28))]; [ControlView addSubview: btnCheckBackView]; If (! [BTN-Check Supervision]) [[BTN-Czech Setfare: NSR Actform Citrate (CGRactam (0, 0, 28, 28))]; [Btnchbackback sq.wew: btn check]; }} // NSLog (@ "Draw With Frame"); // NSLog (@ "Rikt% d,% d,% d,% d", (int) cellFrame.origin.x, (int) cellFrame.origin.y, (int) Selfrem. Size.width, (int) CellFrame.size.height); // NSLog (@ "control scene% d,% d,% d,% d", (int) controlView.frame.origin.x, (int) controlView.frame.origin.y, (int) controlView.frame. Size .width, (int) controlView.frame.size.height); }    

Comments

Popular posts from this blog

mysql - BLOB/TEXT column 'value' used in key specification without a key length -

c# - Using Vici cool Storage with monodroid -

python - referencing a variable in another function? -