Interface IDisplayScaleProvider
Represents a platform-specific way to read the display scale of a native window.
public interface IDisplayScaleProvider
- Extension Methods
Remarks
Obtain the implementation for the current platform from GetProvider().
Methods
GetScale(in NativeWindowInfo)
Gets the display scale of the specified window, where 1.0 means 96 DPI (100 %).
float GetScale(in NativeWindowInfo window)
Parameters
windowNativeWindowInfoThe native window to query.
Returns
- float
The display scale. Implementations must not throw; they return
1.0when the scale can't be determined.