Share via


UITraitCollection.FromDisplayScale(NFloat) Method

Definition

Creates a new UITraitCollection object where only the display scale has been specified.

[Foundation.Export("traitCollectionWithDisplayScale:")]
[ObjCRuntime.BindingImpl(ObjCRuntime.BindingImplOptions.GeneratedCode | ObjCRuntime.BindingImplOptions.Optimizable)]
public static UIKit.UITraitCollection FromDisplayScale(System.Runtime.InteropServices.NFloat scale);
[<Foundation.Export("traitCollectionWithDisplayScale:")>]
[<ObjCRuntime.BindingImpl(ObjCRuntime.BindingImplOptions.GeneratedCode | ObjCRuntime.BindingImplOptions.Optimizable)>]
static member FromDisplayScale : System.Runtime.InteropServices.NFloat -> UIKit.UITraitCollection

Parameters

scale
NFloat

Display scale to set.

Returns

New instance of UITraitCollection with a single element specified.

Attributes

Applies to