tags:

views:

691

answers:

2

Is there a counterpart to the CALayer's anchorPoint for a UIView?

I'd like to rotate my UIView around a point other than the center of the bounds.

Thanks.

+1  A: 

No, if u want to do it U'll have to use the layer I'm pretty sure

Daniel
Thanks,now I know where to look...
Serge
A: 

To follow up on what Daniel said, according to the UIView documentation:

The origin of the transform is the value of the center property, or the layer’s anchorPoint property if it was changed. (Use the layer property to get the underlying Core Animation layer object.)

Therefore, if you set the anchorPoint in the UIView's layer, transforms applied directly to the UIView will occur about that point.

Brad Larson