eclipse.platform.swt icon indicating copy to clipboard operation
eclipse.platform.swt copied to clipboard

Eclipse UI crashes on startup, or requires frequent restarts due to monitor zoom on hi resolution display (GNOME Wayland)

Open ctubbsii opened this issue 11 months ago • 1 comments

Let's make sure issue is not already fixed in latest builds first.

Steps to reproduce

From a fresh installation and clean workspace:

  • Use GNOME Wayland with a high resolution monitor and a scale factor (I used a 2256x1504, 3:2 ratio, 125% scale on my frame.work laptop)
  • Use a second monitor using a standard resolution for comparison of expected behavior (I used an attached HDMI monitor 1920x1080, 16:9 ratio, 100% scale)
  • Because Eclipse opens on the monitor that has focus, try opening Eclipse with the mouse hovering over each monitor during startup

I tried

  • Open Eclipse with the mouse focused on the 3:2 ratio high resolution monitor with 125% zoom, and also
  • Open Eclipse with the mouse focused on the 16:9 ratio FHD resolution monitor with 100% zoom, then drag Eclipse over to the other monitor and maximize the window

I expected: Eclipse should open normally, and I should be able to resize it to full screen on either monitor.

But got: Normal behavior when Eclipse opened on the FHD monitor, but Eclipse crashes when starting up on the 3:2 ratio monitor with 125% zoom. Additionally, if Eclipse is opened on the FHD monitor, then the window is dragged over to the 3:2 ratio monitor, it has some severe problems. Usually it gets confused, and has a popup dialog that cannot be suppressed that pops up asking to restart Eclipse for zoom to take effect. Sometimes it shows UI elements and text very tiny, and drawn poorly, and sometimes it crashes.

I believe this is the same issue first reported at https://bugs.eclipse.org/bugs/show_bug.cgi?id=570470

Here is some relevant log output

From <workspace>/.metadata/.log (not much useful here)

!SESSION 2025-02-27 15:43:52.385 -----------------------------------------------
eclipse.buildId=4.34.0.20241128-0756
java.version=21.0.6
java.vendor=Eclipse Adoptium
BootLoader constants: OS=linux, ARCH=x86_64, WS=gtk, NL=en_US
Framework arguments:  -product org.eclipse.epp.package.java.product
Command-line arguments:  -os linux -ws gtk -arch x86_64 -product org.eclipse.epp.package.java.product

!ENTRY ch.qos.logback.classic 1 0 2025-02-27 15:43:53.616
!MESSAGE Activated before the state location was initialized. Retry after the state location is initialized.

!ENTRY ch.qos.logback.classic 1 0 2025-02-27 15:43:54.371
!MESSAGE Logback config file: /home/christopher/apps/eclipse/workspace/.metadata/.plugins/org.eclipse.m2e.logback/logback.2.7.0.20241001-1350.xml

From the console (also doesn't look very useful):

CompileCommand: exclude org/eclipse/jdt/internal/core/dom/rewrite/ASTRewriteAnalyzer.getExtendedRange bool exclude = true
Feb 27, 2025 3:45:42 PM org.apache.aries.spifly.BaseActivator log
INFO: Registered provider ch.qos.logback.classic.spi.LogbackServiceProvider of service org.slf4j.spi.SLF4JServiceProvider in bundle ch.qos.logback.classic
15:45:43.446 [Start Level: Equinox Container: 58a07594-3b77-447a-87a2-d944d16cbf68] DEBUG org.eclipse.jgit.internal.util.ShutdownHook -- register org.eclipse.jgit.util.FS$FileStoreAttributes$$Lambda/0x00007f91381be408@420171ec with shutdown hook
15:45:43.446 [Start Level: Equinox Container: 58a07594-3b77-447a-87a2-d944d16cbf68] DEBUG org.eclipse.jgit.internal.util.ShutdownHook -- register org.eclipse.jgit.util.FS$FileStoreAttributes$$Lambda/0x00007f91381be408@420171ec with shutdown hook
Gdk-Message: 15:45:47.173: Error flushing display: Broken pipe

Tested under this environment:

  • OS & version: Fedora 41
  • Eclipse IDE/Platform version (as shown in Help > About): Eclipse IDE for Java Developers; Version: 2024-12 (4.34.0); Build id: 20241128-0757
  • Installation package: eclipse-java-2024-12-R-linux-gtk-x86_64.tar.gz

Community

  • [X] I understand reporting an issue to this OSS project does not mandate anyone to fix it. Other contributors may consider the issue, or not, at their own convenience. The most efficient way to get it fixed is that I fix it myself and contribute it back as a good quality patch to the project.

ctubbsii avatar Feb 27 '25 20:02 ctubbsii

The log and console output are from when it crashes on startup using the 3:2 monitor. If it starts up successfully, the other error is just the normal constant dialog asking to restart for zoom changes to take effect. If it happens again, I could add a screenshot, but it's the standard dialog box for that, so a screenshot for that isn't very useful.

ctubbsii avatar Feb 27 '25 20:02 ctubbsii

I am having a similar issue with a laptop and an ultra wide screen. eclipse keeps asking to restart when I move the window, or go to another workspace (not moving the window to another workspace just moving my focus), etc. This is true even if the laptop screen is not involved (do not put the mouse focus to it, etc.).

However, when the laptop screen is turned of (lid down) then the issue disappears.

It looks as though eclipse is getting confused between the dpi of the large screen and the laptop.

clauderobi avatar May 15 '25 21:05 clauderobi

For what it's worth, I've only ever seen this when I've had my FHD monitor to the left of my HiDPI laptop screen in a two monitor setup. I've never seen it when I have my HiDPI laptop screen positioned to the left of two FHD monitors in a three monitor setup.

ctubbsii avatar May 19 '25 18:05 ctubbsii

I’m experiencing the exact same issue.

I’m running Arch Linux with the GNOME (Wayland-only) desktop environment, using fractional scaling and XWayland native scaling enabled via:

gsettings set org.gnome.mutter experimental-features '["scale-monitor-framebuffer", "xwayland-native-scaling"]'

I can confirm @ctubbsii’s findings — the issue only occurs when the FHD screen is positioned on the left.

cristatus avatar Jun 07 '25 07:06 cristatus