The IT department at work recently upgraded me from a 2K display Windows 7 laptop to a 4K display Windows 10 laptop.
The recommended (and I suspect default) resolution on this system is 3840x2160 and recommended size of apps/text is 250%.
The issue with these settings is that not all apps scale properly.
As a result, some of my frequented apps were rendered weird - either the toolbar was too small or the navigation pane had huge icons.
If you are facing similar issues, the steps listed here should work.
Before the WAR:
After the WAR:
Step 1
Create a file called <app name>.exe.manifest.
Step2
Edit the file to include the dxi settings
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
<application xmlns="urn:schemas-microsoft-com:asm.v3">
<windowsSettings>
<dpiAware xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">False</dpiAware>
</windowsSettings>
</application>
</assembly>
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
<application xmlns="urn:schemas-microsoft-com:asm.v3">
<windowsSettings>
<dpiAware xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">False</dpiAware>
</windowsSettings>
</application>
</assembly>
Step3
Copy the file to the location of the binary
Step4
Create a registry key
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\SideBySide\PreferExternalManifest (DWORD) to 1
With windows 10, the manifest has a field dpiaware which informs Windows whether the application will be responsible for it's own dots per pixel computation. (Please see the manifest link for details and comparison of dpiaware vs dpiawareness)
In the steps above, we overrode the application's manifest to use our own. Not all applications have a manifest packaged in their executable, but when they do, it may contain other critical information which you'll need to replicate. So it is a good idea to copy the contents of packaged manifest into your own manifest and modify the dpi value.
If manifest contains
<dpiaware>true</dpiaware>,
modify it to
<dpiaware>false</dpiaware>
Else, the text from step 2 is sufficient.
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\SideBySide\PreferExternalManifest (DWORD) to 1
What we did:
Manifest contains metadata for the application besides some runtime bindings. It is a part of the executable package. The exe can be unzipped using 7zip. The Manifest usually resides in a folder called .res/1033/MANIFEST/.With windows 10, the manifest has a field dpiaware which informs Windows whether the application will be responsible for it's own dots per pixel computation. (Please see the manifest link for details and comparison of dpiaware vs dpiawareness)
In the steps above, we overrode the application's manifest to use our own. Not all applications have a manifest packaged in their executable, but when they do, it may contain other critical information which you'll need to replicate. So it is a good idea to copy the contents of packaged manifest into your own manifest and modify the dpi value.
If manifest contains
<dpiaware>true</dpiaware>,
modify it to
<dpiaware>false</dpiaware>
Else, the text from step 2 is sufficient.
Comments