Menu

#394 HiDPI scaling causes visual glitches

1.9.3.1
closed
None
5
2023-01-16
2017-11-30
No

With display scaling enabled (Windows Settings app -> System section -> Display tab -> Change the size of text, apps, and other items: 125%), some parts of the UI are misdrawn.

The Robocode tagline is not placed correctly:

The battle view is not scaled correctly, and parts of its region is left unpainted:

Reproduced on Robocode 1.9.3.0 on Java 9.0.1 on Windows 10.

Discussion

  • MultiplyByZer0

    MultiplyByZer0 - 2017-11-30

    Sigh, SourceForge...

    View the images here.

     
  • Flemming N. Larsen

    • assigned_to: Flemming N. Larsen
    • Group: 1.9.2.7 --> Future Release
    • Priority: 1 --> 5
     
  • Flemming N. Larsen

    Sorry for the late response.
    I have now made a 1.9.3.1 beta, which should solve the problem by setting sun.java2d.dpiaware=false.

    Try out this file:
    http://robocode.sourceforge.net/files/robocode-1.9.3.1-beta-setup.jar

    It works on my system, running Windows 10 and Java 9.

    When you confirm, I will make a new Robocode release very soon. :-)

     
  • Flemming N. Larsen

    • status: open --> closed
    • Group: Future Release --> 1.9.3.1
     
  • Xor

    Xor - 2023-01-16

    Current fix resolved the glitch but also caused blurry UI, here's a re-fix that actually adds HiDPI support:

    https://github.com/robo-code/robocode/pull/62

    It's actually only a few lines of code, since Java2d supports HiDPI already.

     

    Last edit: Xor 2023-01-16

Log in to post a comment.