I want to get the current position of a UIView after a transform rotate has been applied to it. How can i do that ?
In the UIView doc i found this about the transform property :
"If this property is not the identity transform, the value of the frame property is undefined and therefore should be ignored."
I tried to use center and bounds instead but the result is translated (even when no transform was applied to the rotatedView)
newView.center = rotatedView.center;
newView.bounds = rotatedView.bounds;
newView.transform = rotatedView.transform;
Can anybody help please ?
Thanks in advance, vincent.
If you know the frame before transform, you can use CGRectApplyAffineTransform function to calculate it's value after transformation.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With