Class

CAConstraintLayoutManager

An object that provides a constraint-based layout manager.

Declaration

@interface CAConstraintLayoutManager : NSObject

Overview

You use the shared instance of this object by assigning it to the layoutManager property of any layer objects to which you have added constraints. During a layout update, Core Animation uses the layout manager to update the size and position of the sublayers based on the registered set of constraints.

Constraints let you define a set of geometric relationships between a layer and its sibling layers or between a layer and its superlayer. These relationships are expressed using constraint objects, which are instances of the CAConstraint class. When creating constraints, you can reference a layer by name using that object’s name property. You can also use the special name superlayer to refer to the layer's superlayer.

This class is not meant to be subclassed.

Topics

Creating the layout manager

+ layoutManager

Returns the shared layout manager object.

Relationships

Inherits From

Conforms To

See Also

Layer Basics

CALayer

An object that manages image-based content and allows you to perform animations on that content.

CALayerDelegate

Methods your app can implement to respond to layer-related events.

CAConstraint

A representation of a single layout constraint between two layers.

CALayoutManager

Methods that allow an object to manage the layout of a layer and its sublayers.

CAAction

An interface that allows objects to respond to actions triggered by a CALayer change.

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software