0

I need my (Winform) applications to all scale properly for higher-dpi in Windows 7, Windows 8 / 8.1, and Windows 10. I am confused which option I need for this. I have made my application(s) DPI-aware by adding the below to their manifests:

<application xmlns="urn:schemas-microsoft-com:asm.v3">
    <windowsSettings>
      <dpiAware xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">true</dpiAware>
    </windowsSettings>
</application>

The above comment says

"Indicates that the application is DPI-aware and will not be automatically scaled by Windows at higher DPIs." 

But I am not sure which platforms this works for? I have changed my AutoScaleMode to Dpi and designed at 96dpi. I know that this block of code makes the application(s) DPI-aware but I'm not sure for which platforms?

Chris K
  • 369
  • 1
  • 4
  • 11
  • It does not make your app dpiAware. It merely *promises* that the app scales properly is so the OS does not have to help with its dpi virtualization feature. That promise is not often kept, hard-coding pixels is a very common mistake in a Winforms app, you must test this. – Hans Passant Mar 21 '18 at 15:49
  • Possible duplicate of [How to write WinForms code that auto-scales to system font and dpi settings?](https://stackoverflow.com/questions/22735174/how-to-write-winforms-code-that-auto-scales-to-system-font-and-dpi-settings) – magicandre1981 Mar 21 '18 at 15:53
  • And I am also confused.. Is high-dpi only supported starting with the Windows 10 Creators Update and above?? – Chris K Mar 21 '18 at 21:09

0 Answers0