Editar

Compartir a través de


NSLayoutAnchor<AnchorType>.ConstraintEqualTo Method

Definition

Overloads

ConstraintEqualTo(NSLayoutAnchor<AnchorType>)

Creates a NSLayoutConstraint whose value is equal to that of the constraint of the anchor.

ConstraintEqualTo(NSLayoutAnchor<AnchorType>, nfloat)

Creates a NSLayoutConstraint whose value is equal to that of the constraint of the anchor plus constant pixels.

ConstraintEqualTo(NSLayoutAnchor<AnchorType>)

Creates a NSLayoutConstraint whose value is equal to that of the constraint of the anchor.

[Foundation.Export("constraintEqualToAnchor:")]
public virtual UIKit.NSLayoutConstraint ConstraintEqualTo (UIKit.NSLayoutAnchor<AnchorType> anchor);
abstract member ConstraintEqualTo : UIKit.NSLayoutAnchor<'AnchorType (requires 'AnchorType :> Foundation.NSObject)> -> UIKit.NSLayoutConstraint
override this.ConstraintEqualTo : UIKit.NSLayoutAnchor<'AnchorType (requires 'AnchorType :> Foundation.NSObject)> -> UIKit.NSLayoutConstraint

Parameters

anchor
NSLayoutAnchor<AnchorType>

The NSLayoutAnchor<AnchorType> whose constraint value should be copied.

Returns

A new NSLayoutConstraint.

Attributes

Remarks

As with other methods of this class, this method returns a new NSLayoutConstraint but does not add and activate it to the current UIView.

Applies to

ConstraintEqualTo(NSLayoutAnchor<AnchorType>, nfloat)

Creates a NSLayoutConstraint whose value is equal to that of the constraint of the anchor plus constant pixels.

[Foundation.Export("constraintEqualToAnchor:constant:")]
public virtual UIKit.NSLayoutConstraint ConstraintEqualTo (UIKit.NSLayoutAnchor<AnchorType> anchor, nfloat constant);
abstract member ConstraintEqualTo : UIKit.NSLayoutAnchor<'AnchorType (requires 'AnchorType :> Foundation.NSObject)> * nfloat -> UIKit.NSLayoutConstraint
override this.ConstraintEqualTo : UIKit.NSLayoutAnchor<'AnchorType (requires 'AnchorType :> Foundation.NSObject)> * nfloat -> UIKit.NSLayoutConstraint

Parameters

anchor
NSLayoutAnchor<AnchorType>

The NSLayoutAnchor<AnchorType> whose constraint value should be used.

constant
nfloat

The number of logical pixels to add to the value of anchor.

Returns

Attributes

Remarks

As with other methods of this class, this method returns a new NSLayoutConstraint but does not add and activate it to the current UIView.

Applies to