Bug 406543

Summary: QML applications under wayland do not have window decorations.
Product: [Developer tools] Qt/KDE Flatpak Runtime Reporter: Diane Trout <diane>
Component: generalAssignee: Aleix Pol <aleixpol>
Status: CONFIRMED ---    
Severity: normal CC: nate
Priority: NOR    
Version First Reported In: unspecified   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Diane Trout 2019-04-14 19:36:39 UTC
SUMMARY

When running under wayland a QML application lacks its window decorations when run against runtime 5.12.

I first noticed it with the flatpak of elisa, https://github.com/flathub/org.kde.elisa/issues/6 but I also tested with a minimal qml file using qmlscene and it also lacked window decorations

My minimal qml file

import QtQuick 2.0
import org.kde.plasma.components 2.0 as PlasmaComponents


Text {
    id: helloText
    color: "#0ff"
    text: "hello"
}

I launched the flatpak with "flatpak --devel run --command=bash org.kde.elisa"

And run in the flatpak with "qmlscene hello.qml" or "qmlscene -platform wayland hello.qml" I have no window decorations. Using -platform xcb in the container works. And -platform wayland works outside the container (Debian Testing)

If I downgrade elisa to a version using the 5.11 flatpack the I do get window decorations even when using -platform wayland.


I would like window decorations to be available.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Debian Testing
 
(available in About System)
KDE Plasma Version: 5.14.5
KDE Frameworks Version: 5.54.0
Qt Version: 5.11.3

The elisa flatpak from flathub.

This version works
0f24374c81c606093c8ca8ad3766c663a55e882a005a52a4051971f38c749963 

This version doesn't work.
707a83bcff07a77e300621514b303a43d42e93c3a555979a9b80ecb4892a2e86
Comment 1 Aleix Pol 2019-04-16 13:34:26 UTC
It seems like it's an issue in mutter?
https://gitlab.gnome.org/GNOME/mutter/issues/199
https://codereview.qt-project.org/#/c/231227/
Comment 2 Diane Trout 2019-04-16 17:51:59 UTC
(In reply to Aleix Pol from comment #1)
> It seems like it's an issue in mutter?
> https://gitlab.gnome.org/GNOME/mutter/issues/199
> https://codereview.qt-project.org/#/c/231227/

Are you sure its a mutter issue?

My host is running kwin_wayland

ps auxw | grep kwin
diane    21984  5.3  0.9 3241200 162196 tty4   Sl+  09:20   2:20 /usr/bin/kwin_wayland --xwayland --libinput --exit-with-session=/usr/lib/x86_64-linux-gnu/libexec/startplasma

GNOME_SHELL isn't defined and all my XDG settings are pointing at KDE so the changes in https://codereview.qt-project.org/#/c/231227/ shouldn't be activated?

I don't know about the double buffering problem though.

env | grep XDG
XDG_SESSION_PATH=/org/freedesktop/DisplayManager/Session3
XDG_SEAT=seat0
XDG_SESSION_DESKTOP=KDE
XDG_SESSION_TYPE=wayland
XDG_CURRENT_DESKTOP=KDE
XDG_SEAT_PATH=/org/freedesktop/DisplayManager/Seat0
XDG_SESSION_CLASS=user
XDG_VTNR=4
XDG_SESSION_ID=29

And I tried looking through gdb's info sharedlibraries for the elisa process and couldn't find any reference to libmutter.

I tried dolphin from flathub 74b2d7b235a623ea8dd5bebdfb6c9d1c44b5365c2d1811be52b6218ee15c1953 and it had no decorations as well.

I thought kontact worked, but I just remembered we forced it to use xcb because WebKit was broken under wayland.
Comment 3 Aleix Pol 2019-04-16 17:59:13 UTC
I'm using kwin_wayland (master) too and I don't have this issue.
Comment 4 Diane Trout 2019-04-17 05:20:35 UTC
Looks like I need to try a newer kwin. Thanks for the hint.