-
Notifications
You must be signed in to change notification settings - Fork 162
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Windows GUI: Dark mode for HTML view #857
Conversation
Inject CSS style into the HTML to give it a dark mode.
Great! |
No idea for that one. This application is still using the old IE engine for HTML which isn't aware of dark mode as far as I know. There is a newer TEdgeBrowser for displaying HTML using the Edge engine but probably would not work on older Windows. |
We dropped WinXP and our minimal requirement is Win7 now so I think it should be fine, if you are motivated go ahead on the switch. |
Windows 8.1 and below is dropped for this according to https://learn.microsoft.com/en-us/microsoft-edge/webview2/. |
Win7 is still used by few % of people despite it is EOL for a long time and it would not worth it to drop this support yet or bother people with an additional install, but if you don't mind we would like to use your skills when you are here, it would be great to have a patch ready and when we consider that it is time to switch we just merge it. We just don't promise about the time line. |
(Note that this PR won't be in the next release as we already launched the build process, it will be for the one after the next one) |
Are there plans to use the Qt version for Windows? If so maybe better to spend effort on improving the Qt one instead. The latest Qt has native dark mode built-in for Windows without needing to do anything (looks and works better than this VCL implementation). By the way, the Windows 11 context menu if implemented can be used for any MediaInfo version on Windows. It is not dependent on this VCL version so it is fine to spend effort on that even if there are plans to retire the VCL version in the future. |
True
True too. We are torn between polishing the VCL and switching to Qt at some point, but the gap between VCL and what is currently in Qt version is huge and we always postpone the full development. |
It is in 24.05.1. |
@JeromeMartinez I wasn't going to do this if it required significant code changes but it didn't so here it is: https://github.com/cjee21/MediaInfo/tree/edge-webview2 It should use Edge WebView2 engine when available else fallback to IE engine. I only tested on Windows 11. #853 (comment) is fixed by this, at least when using the Edge engine. The scrollbar is still not dark mode. I guess this requires some API (maybe this?) to set the current scheme but no idea how. If it works on Windows 7 and 10 as well and you are satisfied with it, then I can make the pull request. EDIT: Forgot to mention, need to do the steps under |
Edit: Deleting temporary HTML file is now in main and no longer part of this patch
|
|
@JeromeMartinez Tried building Qt version using latest Qt (6.7.1) and latest MSVC (2022) just to see how it looks. Here's how it looks on Windows 11: Changes I made to Qt version for testing are available here: https://github.com/cjee21/MediaInfo/tree/Qt |
Please do open a PR, easier to track. |
@JeromeMartinez I made some changes to the Qt version while testing. The changes are available here: https://github.com/cjee21/MediaInfo/tree/Qt. If you would like me to make a PR for this as well, just let me know. This is how my branch currently looks on Windows 11 and Ubuntu: |
We are also interested in updates on the Qt version so PR please, thank you! |
Inject CSS style into the HTML to give it a dark mode.
Let me know if you want to make changes to how it looks.