EdgeAligningView
@MainActor
public final class EdgeAligningView<CustomView> : UIView where CustomView : UIView
Container view that allows its CustomView to have lose connection to the margins of the container according to the
settings provided in EdgeAligningView.flexibleEdges
-
Represents an edge of
See moreEdgeAligningViewDeclaration
Swift
public enum Edge : CaseIterable -
Set of edge constraints to be set as loose.
Declaration
Swift
@MainActor public var flexibleEdges: Set<Edge> { get set } -
Contained view.
Declaration
Swift
@MainActor public var customView: CustomView { get set } -
Preferred priority of the internal constraints.
Declaration
Swift
@MainActor public var preferredPriority: UILayoutPriority { get set } -
Initializes and returns a newly allocated
EdgeAligningViewDeclaration
Swift
@MainActor public init( with customView: CustomView, flexibleEdges: Set<Edge> = [.top], preferredPriority: UILayoutPriority = .required )Parameters
customViewAn instance of
CustomViewflexibleEdgesSet of edges to be set as loose.
preferredPriorityPreferred priority of the internal constraints.
-
Initializes and returns a newly allocated view object with the specified frame rectangle.
Declaration
Swift
@MainActor public override init(frame: CGRect)Parameters
frameThe frame rectangle for the view, measured in points. The origin of the frame is relative to the superview in which you plan to add it.
-
Initializes and returns a newly allocated view object with the specified frame rectangle.
Declaration
Swift
@MainActor public init( frame: CGRect, flexibleEdges: Set<Edge> = [], preferredPriority: UILayoutPriority = .required )Parameters
frameThe frame rectangle for the view, measured in points. The origin of the frame is relative
flexibleEdgesSet of edges to be set as loose.
preferredPriorityPreferred priority of the internal constraints. to the superview in which you plan to add it.
-
A Boolean value that indicates whether the receiver depends on the constraint-based layout system.
Declaration
Swift
@MainActor public override class var requiresConstraintBasedLayout: Bool { get } -
Updates constraints for the view.
Declaration
Swift
@MainActor public override func updateConstraints()