Table of Contents

Interface IDeviceInfo

Namespace
Xui.Core.DI
Assembly
Xui.Core.dll

Provides information about the current device, platform, and user preferences. Resolved via this.GetService<IDeviceInfo>() from any View. The emulator replaces this with a mock to simulate phone or tablet form factors.

public interface IDeviceInfo

Properties

AccessibilityFontScale

Accessibility font scale multiplier (1.0 = default).

NFloat AccessibilityFontScale { get; }

Property Value

NFloat

ColorScheme

Light or dark appearance preference.

ColorScheme ColorScheme { get; }

Property Value

ColorScheme

FormFactor

Gets the form factor of the current device.

DeviceFormFactor FormFactor { get; }

Property Value

DeviceFormFactor

Platform

Gets the operating system the app is running on.

DevicePlatform Platform { get; }

Property Value

DevicePlatform

PointerModel

Gets the primary pointing device available to the user.

PointerModel PointerModel { get; }

Property Value

PointerModel

PrefersHighContrast

True if the user has requested high-contrast mode.

bool PrefersHighContrast { get; }

Property Value

bool

PrefersReducedMotion

True if the user has requested reduced motion.

bool PrefersReducedMotion { get; }

Property Value

bool