Bug 476777 - [Wayland] Eclipse modal dialog shows without decorations, cannot be moved, renders partially off screen
Summary: [Wayland] Eclipse modal dialog shows without decorations, cannot be moved, re...
Status: RESOLVED DOWNSTREAM
Alias: None
Product: kwin
Classification: Plasma
Component: general (other bugs)
Version First Reported In: git-stable-Plasma/5.27
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-11-10 07:00 UTC by Oded Arbel
Modified: 2023-11-10 09:27 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments
A screenshot showing the problem (750.33 KB, image/png)
2023-11-10 07:00 UTC, Oded Arbel
Details
Screenshot showing how the windows are rendered (180.39 KB, image/png)
2023-11-10 07:07 UTC, Oded Arbel
Details
Screenshot showing how the modal dialog is rendered relative to a floating window (186.71 KB, image/png)
2023-11-10 07:09 UTC, Oded Arbel
Details
Kwin debug console showing the surfaces (48.70 KB, image/png)
2023-11-10 07:09 UTC, Oded Arbel
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Oded Arbel 2023-11-10 07:00:23 UTC
Created attachment 162998 [details]
A screenshot showing the problem

SUMMARY
Running the latest Eclipse development build (2023-12M2), with GTK 3.24.37, when the Eclipse updates certificate confirmation dialog comes up, it is rendered without decorations, in a fixed position relative to the main Eclipse window and cannot be moved. Furthermore - it is rendered partially off screen, making its action buttons inaccessible.

Other modal dialogs from Eclipse seem to be working fine.

STEPS TO REPRODUCE
1. Download an eclipse 2023-12 development build (for example, from https://www.eclipse.org/downloads/packages/release/2023-12/m2) and run it.
2. Try to install some plugins using "Help"-> "Install new software".
3. Observe that the software updates modal dialog works fine. Select something to install and complete the Wizard. After downloading the update, a certificate confirmation dialog should come up to let the user select which certificates they trust.

OBSERVED RESULT
See screenshots

EXPECTED RESULT
The certificate dialog should also present as a standard utility window that can be moved around.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: 
Operating System: KDE neon Testing Edition
KDE Plasma Version: 5.27.9
KDE Frameworks Version: 5.112.0
Qt Version: 5.15.11
Kernel Version: 6.5.4-060504-generic (64-bit)
Graphics Platform: offscreen
Processors: 20 × 12th Gen Intel® Core™ i7-12700H
Memory: 31.0 GiB of RAM
Graphics Processor: Mesa Intel® Graphics

ADDITIONAL INFORMATION
I'll add more details with attachments shortly.
Comment 1 Oded Arbel 2023-11-10 07:07:34 UTC
Created attachment 162999 [details]
Screenshot showing how the windows are rendered

With Spectactle's "window screenshot" we can see how the certificate dialog is rendered relative to the maximized Eclipse window. Everything that is rendered below the bottom edge of the main window is obscured by the panel or is actually off screen.
Comment 2 Oded Arbel 2023-11-10 07:09:04 UTC
Created attachment 163000 [details]
Screenshot showing how the modal dialog is rendered relative to a floating window

If the Eclipse window is not maximized, the certificate dialog is rendered completely under the main window. By moving Eclipse to my vertical screen, I can access the dialog's action buttons.
Comment 3 Oded Arbel 2023-11-10 07:09:27 UTC
Created attachment 163001 [details]
Kwin debug console showing the surfaces
Comment 4 Oded Arbel 2023-11-10 07:19:34 UTC
KWin debug console's window list only shows the main Eclipse window.
I can use kwin's Kwin/org.kde.Kwin::queryWindowInfo DBus method to get the window info for the modal dialog - it is basically the details for the Eclipse main window:

  Arguments: [Argument: a{sv} {"activities" = [Variant(QStringList): {"114ebbc8-f947-493d-bc5e-3762eab23c9a"}], "caption" = [Variant(QString): "kappas - java-server/src/main/java/club/kappas/api/entities/Users.java - Eclipse Platform"], "clientMachine" = [Variant(QString): ""], "desktopFile" = [Variant(QString): "Eclipse"], "desktops" = [Variant(QStringList): {"{e3664924-83a8-4444-b84a-d2b1a5d0d071}"}], "fullscreen" = [Variant(bool): false], "height" = [Variant(double): 741], "keepAbove" = [Variant(bool): false], "keepBelow" = [Variant(bool): false], "localhost" = [Variant(bool): true], "maximizeHorizontal" = [Variant(int): 2], "maximizeVertical" = [Variant(int): 0], "minimized" = [Variant(bool): false], "noBorder" = [Variant(bool): false], "resourceClass" = [Variant(QString): "Eclipse"], "resourceName" = [Variant(QString): "java"], "role" = [Variant(QString): ""], "shaded" = [Variant(bool): false], "skipPager" = [Variant(bool): false], "skipSwitcher" = [Variant(bool): false], "skipTaskbar" = [Variant(bool): false], "type" = [Variant(int): 0], "uuid" = [Variant(QString): "{c18f6283-452c-416f-8d75-fc421d608efe}"], "width" = [Variant(double): 1200], "x" = [Variant(double): 0], "y" = [Variant(double): 0]}]

When I do the same thing for an Eclipse modal dialog that shows correctly (such as the "Find" or "Open type" dialogs), I can see it has a different UUID than the main window, for example:
  Arguments: [Argument: a{sv} {"activities" = [Variant(QStringList): {"114ebbc8-f947-493d-bc5e-3762eab23c9a"}], "caption" = [Variant(QString): "Open Type"], "clientMachine" = [Variant(QString): ""], "desktopFile" = [Variant(QString): "Eclipse"], "desktops" = [Variant(QStringList): {"{a31763c5-0597-4253-9438-632318c6a38f}"}], "fullscreen" = [Variant(bool): false], "height" = [Variant(double): 618], "keepAbove" = [Variant(bool): false], "keepBelow" = [Variant(bool): false], "localhost" = [Variant(bool): true], "maximizeHorizontal" = [Variant(int): 0], "maximizeVertical" = [Variant(int): 0], "minimized" = [Variant(bool): false], "noBorder" = [Variant(bool): false], "resourceClass" = [Variant(QString): "Eclipse"], "resourceName" = [Variant(QString): "java"], "role" = [Variant(QString): ""], "shaded" = [Variant(bool): false], "skipPager" = [Variant(bool): false], "skipSwitcher" = [Variant(bool): false], "skipTaskbar" = [Variant(bool): false], "type" = [Variant(int): 0], "uuid" = [Variant(QString): "{e23f241e-dcb6-4647-b641-11640aa43043}"], "width" = [Variant(double): 398], "x" = [Variant(double): 402], "y" = [Variant(double): 652]}]

A normal working modal dialog also shows in KWin debug console's window list, which the broken certificates dialog does not.
Comment 5 Oded Arbel 2023-11-10 07:22:32 UTC
Another thing about the KWin debug console - in screenshot 4 we can see that the certificates dialog is shown as a "child surface" of the main Eclipse widow (not that I know what it means): this is also different than standard Eclipse modal dialogs, with which the KWin debug console lists their surfaces as independent on the surfaces list.
Comment 6 Oded Arbel 2023-11-10 07:23:23 UTC
I'm using kwin from Neon stable (user) build: 4:5.27.9-0xneon+22.04+jammy+release+build47
Comment 7 David Redondo 2023-11-10 09:27:02 UTC
This is an eclipse bug Please report it there.