Posts

Showing posts with the label anchor point

Understanding Anchor point in iOS

Image
Just to take notes for this regarding anchor point in iOS. This is taken from  developer.apple.com Specifying a Layer’s Geometry While layers and the layer-tree are analogous to views and view hierarchies in many ways, a layer's geometry is specified in a different, and often simpler, manner. All of a layer’s geometric properties, including the layer’s transform matrices, can be implicitly and explicitly animated. Figure 1  shows the properties used to specify a layer's geometry in context. Figure 1   CALayer geometry properties The  position  property is a  CGPoint  that specifies the position of the layer relative to its superlayer, and is expressed in the superlayer's coordinate system. The  bounds  property is a  CGRect  that provides the size of the layer ( bounds.size ) and the origin ( bounds.origin ). The bounds origin is used as the origin of the graphics context when you override a layer's drawing met...