MediaInfo icon indicating copy to clipboard operation
MediaInfo copied to clipboard

MediaInfo 23.07 is still not DPI awareness

Open NewUserHa opened this issue 2 years ago • 2 comments

MediaInfo 23.07 is still not DPI awareness, this issue is since from version 18.05. image very blurry vs manually changed dpi by application: image

win10

NewUserHa avatar Aug 08 '23 12:08 NewUserHa

maybe the developer still use 1080p monitor

userzzzq avatar Nov 18 '23 13:11 userzzzq

maybe the developer still use 1080p monitor

True. also our sponsors, so not their priority, but we understand that this is annoying, we need at some point to find how to fix that. Patch welcome if you know.

JeromeMartinez avatar Nov 18 '23 13:11 JeromeMartinez

If manually setting the DPI works as mentioned in the first post, adding the following to the manifest should do it. No other changes needed if everything is displayed properly after enabling high DPI.

<asmv3:application>
    <asmv3:windowsSettings>
        <dpiAware>true</dpiAware>
        <dpiAwareness>PerMonitorV2</dpiAwareness>
    </asmv3:windowsSettings>
</asmv3:application>

For GDI-based applications:

<asmv3:application>
    <asmv3:windowsSettings>
        <gdiScaling>true</gdiScaling>
    </asmv3:windowsSettings>
</asmv3:application>

Edit: browsing this repo it seems MediaInfo is using VCL, in that case maybe this will help: https://blogs.embarcadero.com/windows-10-and-modern-high-dpi-display-support-in-delphi-and-c-builder/

cjee21 avatar May 17 '24 07:05 cjee21

I tried implementing high DPI support to MediaInfo. Here's how it looks compared to existing version at 150% scale. Screenshot 2024-05-18 212844

Overall everything seems to look fine. There's a bit of alignment difference in the menu bar and the sponsor(AD) button became blue on hover for some reason. I do not know how to further improve this.

Screenshot 2024-05-18 221828 Here's how it compares in Process Explorer showing the DPI-awareness. I noticed the official MediaInfo is not built with DEP and ASLR enabled?

cjee21 avatar May 18 '24 13:05 cjee21

I fixed the sponsor(AD) button became blue on hover issue. Does this look okay? (screenshots taken with DPI set to 150% scale) Screenshot 2024-05-19 001821 Screenshot 2024-05-19 001848 Screenshot 2024-05-19 001859

Should I create a pull request?

cjee21 avatar May 18 '24 16:05 cjee21

Should I create a pull request?

It would be greatly appreciated!

I noticed the official MediaInfo is not built with DEP and ASLR enabled?

We checked a bit that some time ago but didn't finish to check as we don't know much about it so we weren't sure about what we do, if you have a patch ready we take it :).

JeromeMartinez avatar May 18 '24 18:05 JeromeMartinez

We checked a bit that some time ago but didn't finish to check as we don't know much about it so we weren't sure about what we do, if you have a patch ready we take it :).

For enabling DEP and ASLR, just need to enable these two options in Project Options: Screenshot 2024-05-19 153510

It appears to be auto-enabled here so I don't know whether these settings are saved in the project file or not.

cjee21 avatar May 19 '24 07:05 cjee21