Contents

rightAnchor

A layout anchor representing the right edge of the layout guide’s frame.

Declaration

var rightAnchor: NSLayoutXAxisAnchor { get }

Discussion

Use this anchor to create constraints with the layout guide’s right edge. You can combine this anchor only with a subset of the NSLayoutXAxisAnchor anchors. You can combine a rightAnchor with another rightAnchor, a leftAnchor, or a centerXAnchor. For more information, see NSLayoutAnchor.

See Also

Creating Constraints Using Layout Anchors