Skip to content
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

Size and Position values need to be scaled on High DPI screens #11

Open
hanjo opened this issue Jan 16, 2025 · 0 comments
Open

Size and Position values need to be scaled on High DPI screens #11

hanjo opened this issue Jan 16, 2025 · 0 comments

Comments

@hanjo
Copy link

hanjo commented Jan 16, 2025

Hi,

I have a 4k screen which I run at 175% in Windows.

For example, if I want to have a window of 1/4 the width and 1/4 the height of my screen in the bottom right corner, I would expect that I need to use these parameters:

WWidth=960 ;1/4 of 3840
WHeight=540 ;1/4 of 2160
WX=2880 ;3840-960
WY=1620 ;2160-540

In fact, I need to divide these values with my scale factor of 1.75 to get to the values that yield the desired outcome, which are:

WWidth=549
WHeight=309
WX=1646
WY=926

If I set the high DPI compatibility settings of the application like shown in the screenshot below, the above mentioned actual values can be used. I don't know if this is a lot of effort, but I think it would be good to check for the screens' scaling factor on startup.

Thanks a lot!

Image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant