-
-
Notifications
You must be signed in to change notification settings - Fork 75
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
Bug: Fix/improve DPI handling #99
Comments
Blegh, so ugly. I'm aware and I'm very sorry. I've already been messing with it for hours, but the current combination of winforms/syncfusion just isn't working out. So I'll probably have to rebuild the entire app from the ground up, you can imagine I'm not really looking forward to that :p |
I've created a ticket: [hassagent-112] I'm closing this ticket, not because I'm not doing it, but to keep the GitHub list tidy and all my todo's in one place. I'll report back here when I've fixed this! |
@LAB02-Admin what about disabling the https://docs.microsoft.com/en-us/dotnet/framework/configure-apps/file-schema/winforms/windows-forms-add-configuration-element (check the Windows is able to handle the app resizing ok, as far as I can see: |
Yea that was my initial workaround, but then the new webview doesn't render correctly [#62] :( |
@LAB02-Admin with this workaround the webview sizing is correct for me 🤔So not sure what was causing issues in #62 |
Oh, interesting! I'll look into it and do some more tests, thanks :) |
I wanted to test this by adding an app-config file in the HASS.Agent directory. Unfortunately it does not seem to work. Might need to be defined in the application itself to be read? HASS.Agent.exe.config <?xml version="1.0" encoding="utf-8"?>
<configuration>
<System.Windows.Forms.ApplicationConfigurationSection>
<add key="DpiAwareness" value="false" />
</System.Windows.Forms.ApplicationConfigurationSection>
</configuration> Update: "configProperties": {
"System.Reflection.Metadata.MetadataUpdater.IsSupported": false,
"Switch.System.Windows.DoNotScaleForDpiChanges": true
} |
Implemented in the latest beta, let me know how it works out: https://github.com/LAB02-Research/HASS.Agent/releases/tag/2022.13.0-beta2 |
@LAB02-Admin Hi! Yes, it works for me. Thank you! |
Describe the bug
Despite
HASS.Agent
app reporting that it isPer-monitor DPI Aware
the DPI processing is not correct.It seems that only the main window looks ok, all other windows have elements sizing issues.
Current workaround is to override DPI settings for the
HASS.Agent
executable with the "System (Enhanced)" value (which disables DPI handling by the application).Possible solutions: improve interface scaling or make the app report itself as non-DPI Aware to let the OS handle scaling.
To Reproduce
HASS.Agent
appExpected behavior
Interfaces scales correctly
Screenshots
Misc info (please complete the following information):
winver.exe
output): Windows 11 Pro 22H2 22621.160Please check what's applicable (multiple answers possible):
The text was updated successfully, but these errors were encountered: