Skip to main content

ON.DisplaySize<T>(Nullable<T>, Nullable<T>, Nullable<T>, Nullable<T>, Nullable<T>, Nullable<Size>, Nullable<Size>, Nullable<Size>, Nullable<Size>) Method

Selects the value of a value type to be applied depending on the device screen size.

Namespace: DevExpress.Maui.Core

Assembly: DevExpress.Maui.Core.dll

NuGet Package: DevExpress.Maui.Core

Declaration

public static T DisplaySize<T>(
    T? extraSmall = null,
    T? small = null,
    T? medium = null,
    T? large = null,
    T? extraLarge = null,
    Size? smallThreshold = null,
    Size? mediumThreshold = null,
    Size? largeThreshold = null,
    Size? extraLargeThreshold = null
)
    where T : struct

Optional Parameters

Name Type Default Description
extraSmall Nullable<T> null

The value to be applied on devices with the Extra Small screen size class.

small Nullable<T> null

The value to be applied on devices with the Small screen size class.

medium Nullable<T> null

The value to be applied on devices with the Medium screen size class.

large Nullable<T> null

The value to be applied on devices with the Large screen size class.

extraLarge Nullable<T> null

The value to be applied on devices with the Extra Large screen size class.

smallThreshold Nullable<Size> null

Specifies the lower boundary that restrains the Small screen size class.

mediumThreshold Nullable<Size> null

Specifies the lower boundary that restrains the Medium screen size class.

largeThreshold Nullable<Size> null

Specifies the lower boundary that restrains the Large screen size class.

extraLargeThreshold Nullable<Size> null

Specifies the lower boundary that restrains the Extra Large screen size class.

Type Parameters

Name Description
T

The reference type.

Returns

Type Description
T

The value selected based on the device screen size class.

See Also