SetProcessDpiAwarenessContext
SetProcessDpiAware (and related functions sometimes referred to by the truncated form “SetProcessDpiA…”) are Windows API mechanisms for controlling how a process handles high-DPI scaling. They allow an application to declare its level of DPI awareness so that the operating system can scale graphics and text appropriately on displays with different DPI settings. The goal is to avoid blurry UI and ensure consistent sizing across monitors.
The legacy API SetProcessDPIAware marks the calling process as DPI aware at the system level. It is
A more general approach is SetProcessDpiAwareness, introduced with Windows 8.1. This function allows you to specify
For finer control, SetProcessDpiAwarenessContext (Windows 10) accepts a DPI_AWARENESS_CONTEXT value, including options such as UNAWARE, SYSTEM_AWARE,
Guidance generally favors declaring DPI awareness in the application manifest (for modern Windows versions) and using