UIView.IntrinsicContentSize Property

Definition

The size of the intrinsic content of the UIView.

[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.iOS, 6, 0, ObjCRuntime.PlatformArchitecture.All, null)]
[get: Foundation.Export("intrinsicContentSize")]
[get: ObjCRuntime.Introduced(ObjCRuntime.PlatformName.iOS, 6, 0, ObjCRuntime.PlatformArchitecture.All, null)]
public virtual CoreGraphics.CGSize IntrinsicContentSize { get; }
member this.IntrinsicContentSize : CoreGraphics.CGSize

Property Value

The default value is {NoIntrinsicMetric, NoIntrinsicMetric}.

Attributes

Remarks

Some views, such as UILabels, have a natural intrinsic size that is not related to the actual Frame that contains the entirety of the UIView. This property allows the UIView to tell the Auto Layout system what SizeF it would prefer to be.

If a UIView has no intrinsic size, it should return the default {NoIntrinsicMetric,NoIntrinsicMetric} value.

Applies to

See also