SizeConstraint
public struct SizeConstraint : Hashable, CustomStringConvertible
Defines the maximum size for a measurement.
Currently this constraint type can only handles layout where the primary (breaking) axis is horizontal (row in CSS-speak).
-
The width constraint.
Declaration
Swift
@SizeConstraint .UnconstrainedInfiniteAxis public var width: Axis { get set }
-
The height constraint.
Declaration
Swift
@SizeConstraint .UnconstrainedInfiniteAxis public var height: Axis { get set }
-
Declaration
Swift
public var description: String { get }
-
Declaration
Swift
public static var unconstrained: SizeConstraint { get }
-
Declaration
Swift
public init(_ size: CGSize)
-
Declaration
Swift
public init(width: CGFloat)
-
Declaration
Swift
public init(height: CGFloat)
-
Declaration
Swift
public var minimum: CGSize { get }
-
Declaration
Swift
public var maximum: CGSize { get }
-
Declaration
Swift
public func inset(width: CGFloat, height: CGFloat) -> SizeConstraint
-
Declaration
Swift
public func inset(by insets: UIEdgeInsets) -> SizeConstraint
-
Represents a size constraint for a single axis.
See moreDeclaration
Swift
public enum Axis : Hashable, CustomStringConvertible
-
This property wrapper checks the value of
See moreatMost
cases, and turns it into anunconstrained
axis if the value equalsgreatestFiniteMagnitude
orisInfinite
.Declaration
Swift
@propertyWrapper public struct UnconstrainedInfiniteAxis : Equatable, Hashable