Skip to main content

WindowsFormsSettings.SetDPIAware() Method

Enables system DPI awareness mode for the current process.

Namespace: DevExpress.XtraEditors

Assembly: DevExpress.Utils.v23.1.dll

NuGet Packages: DevExpress.Utils, DevExpress.Wpf.Core


public static void SetDPIAware()


In system DPI awareness mode, applications scale controls based on the DPI setting of the primary monitor. When the application is moved to a monitor with a different scale factor, the window is scaled by the system, making controls appear blurry.

The SetDPIAware method delegates its execution to the SetProcessDPIAware WinApi method.

To enable “Per-Monitor (v2)” DPI awareness mode, use the WindowsFormsSettings.SetPerMonitorDpiAware method.

See High DPI Desktop Application Development on Windows to learn more.

See Also