The insets (in points) from the view’s frame that define its content rectangle.
SDK
- macOS 10.7+
Framework
- App
Kit
Declaration
var alignmentRectInsets: NSEdge Insets { get }
Discussion
The default value is an NSEdge
structure with the value 0
for each component. Custom views that draw ornamentation around their content can override this property and return insets that align with the edges of the content, excluding the ornamentation. This allows the constraint-based layout system to align views based on their content, rather than just their frame.
Custom views whose content location can’t be expressed by a simple set of insets should override alignment
and frame(for
to describe their custom transform between alignment rectangle and frame.