UIView

public extension UIView
  • Sets translatesAutoresizingMaskIntoConstraints to false.

    Declaration

    Swift

    func activateAutoLayout()
  • Centers view Horizontally relative to a superview.

    Declaration

    Swift

    func centerH(relativeTo view: UIView)

    Parameters

    view

    The view to use as a reference when centering.

  • Centers view Vertically relative to a superview.

    Declaration

    Swift

    func centerV(relativeTo view: UIView)

    Parameters

    view

    The view to use as a reference when centering.

  • Centers view relative to a superview.

    Declaration

    Swift

    func center(relativeTo view: UIView)

    Parameters

    view

    The view to use as a reference when centering.