Instance Property

zPosition

The layer’s position on the z axis. Animatable.

Declaration

@property CGFloat zPosition;

Discussion

The default value of this property is 0. Changing the value of this property changes the front-to-back ordering of layers onscreen. Higher values place this layer visually closer to the viewer than layers with lower values. This can affect the visibility of layers whose frame rectangles overlap.

The value of this property is measured in points. The range of this property is single-precision, floating-point -greatestFiniteMagnitude to greatestFiniteMagnitude.

See Also

Modifying the Layer Geometry

frame

The layer’s frame rectangle.

bounds

The layer’s bounds rectangle. Animatable.

position

The layer’s position in its superlayer’s coordinate space. Animatable.

anchorPointZ

The anchor point for the layer’s position along the z axis. Animatable.

anchorPoint

Defines the anchor point of the layer's bounds rectangle. Animatable.

contentsScale

The scale factor applied to the layer.