godotengine / godot

Godot Engine – Multi-platform 2D and 3D game engine
https://godotengine.org
MIT License
88.94k stars 20.17k forks source link

Different TextEdit preview on HiDPI display #35586

Open timothyqiu opened 4 years ago

timothyqiu commented 4 years ago

Godot version: 3.2 RC3

OS/device including version: macOS 10.15.2

Issue description:

On a HiDPI display, the TextEdit preview in the editor is inconsistent with the actual one:

screenshot

As in the screenshot:

  1. Only three lines are displayed, while it's all four lines when running
  2. The display area (highlighted) shown in the minimap only covers two lines, but it's actually three lines shown in the preview, and four when running

Steps to reproduce:

  1. Open Godot on a HiDPI display, or set the Display Scale to 200%
  2. Create a new scene, and add a TextEdit
  3. Make four lines of text, and set the size to 120x75, you can also turn on the minimap

Minimal reproduction project: TextEditTest.zip

KoBeWi commented 3 years ago

Can anyone still reproduce this bug in Godot 3.2.3 or any later release?

timothyqiu commented 3 years ago

Yes. I can still reproduce this in 3.2.4 beta4.

With seamless display scaling implemented, it's now also seen on a low-dpi monitor if there's any hidpi monitor available.

截屏2020-12-15 上午9 58 06
kitbdev commented 4 months ago

Can reproduce in 3.5, but cannot reproduce in 4.0 or later using DisplayScale set to 200%.