LayoutValueRepresentable

public protocol LayoutValueRepresentable

Type which can reprent value, Mostly used with autolayouts, but not limited to it. Contains some utility methods to create margins, insets etc.

  • Raw value

    Declaration

    Swift

    var rawValue: CGFloat { get }
  • pixel Extension method

    One pixel value based on device scale

    Declaration

    Swift

    public static var pixel: CGFloat { get }
  • by(_:) Extension method

    multiply value with rawValue.

    Declaration

    Swift

    public func by(_ multiplier: CGFloat) -> CGFloat
  • edgeInsets() Extension method

    edgeInsets with values.

    Declaration

    Swift

    public func edgeInsets() -> UIEdgeInsets
  • hRect(_:) Extension method

    create horizontal rect with rawValue.

    Declaration

    Swift

    public func hRect(_ value: Self) -> UIEdgeInsets
  • vRect(_:) Extension method

    create vertical rect with rawValue.

    Declaration

    Swift

    public func vRect(_ value: Self) -> UIEdgeInsets