Openra: Reestablish "DisableWindowsDPIScaling" option in settings which was removed with release 20200503

Created on 29 May 2020  路  6Comments  路  Source: OpenRA/OpenRA

REQUEST MOTIVATION
With the latest release 20200503, the settings property "DisableWindowsDPIScaling" was removed which denies the user to play a the native screen resolution if OS DPI scaling is set to a different value than 1.
Please reenable the option "DisableWindowsDPIScaling" in the settings so that the advanced user can choose depending on his needs.

PROPOSED SOLUTION
As far as I have seen, enabling the option "DisableWindowsDPIScaling" leads to necessary adaptions in at least

  • Sdl2PlatformWindow.cs
  • Renderer.cs

EXPECTED SIDE EFFECTS

  • unknown (due to my lack of knowledge of the source code)

ALTERNATIVES
The Windows 10 compatibility mode allows to disable the DPI scaling for applications. However, this does not work: In some parts of the code the DPI scaling is correctly recognized to be 1, but the native resolution of the screen is still considered including the OS DPI scaling.

IdeWishlist

Most helpful comment

If you install the test build from https://github.com/pchote/OpenRA/releases/tag/release-20200503-graphicstest1 you will be able to set OPENRA_DISPLAY_SCALE to 1 using the instructions I linked just above.

All 6 comments

The DisableWindowsDPIScaling variable was added to allow testing and developing of our own HiDPI support, which was finally compled in the latest release. We hadn't considered your use case for this, and I would personally be against restoring a special case flag just for this.

Instead, we can generalize the OPENRA_DISPLAY_SCALE environment variable override that is currently only used on Linux to work on macOS and Windows too. You can then set the override through the windows GUI.

If you install the test build from https://github.com/pchote/OpenRA/releases/tag/release-20200503-graphicstest1 you will be able to set OPENRA_DISPLAY_SCALE to 1 using the instructions I linked just above.

@pchote : Nice, this works to solve the issue.
(setting the environmental variable is a little bit less comfortable than using the settings.yaml but I agree that as long as there are not more people with this issue, there is no sense in making more effort).

Hi, here, so currently OpenRA cannot set the OPENRA_DISPLAY_SCALE to disable the DPI right?

I think for laptop user this function is quite important for the DPI is always set to 1.25+ otherwise the text will be too small in some text/code editor.

As mentioned above, I have a commit that adds the environment variable parsing to Windows, which I will PR before the next playtest is branched.

Question: does Linux also have DPI settings? can we also make one for Linux system user?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Hammerfest picture Hammerfest  路  4Comments

MlemandPurrs picture MlemandPurrs  路  4Comments

TheMightyAltroll picture TheMightyAltroll  路  3Comments

Mailaender picture Mailaender  路  5Comments

dnqbob picture dnqbob  路  3Comments