<div dir="ltr"><div dir="ltr">Thanks very much for this detailed authoritative explanation, Nyall.  I have a couple of specific comments below...<br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, Jan 17, 2024 at 10:29 PM Nyall Dawson <<a href="mailto:nyall.dawson@gmail.com">nyall.dawson@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><br><br>On Thu, 18 Jan 2024 at 13:56, chris hermansen via QGIS-User <<a href="mailto:qgis-user@lists.osgeo.org" target="_blank">qgis-user@lists.osgeo.org</a>> wrote:<br>><br>> Adam and list,<br>><br>> On Wed, Jan 17, 2024 at 5:34 PM Adam Nielsen <<a href="mailto:a.nielsen@shikadi.net" target="_blank">a.nielsen@shikadi.net</a>> wrote:<br>>><br>>> > I have been trying to find a mostly definitive and mostly up-to-date<br>>> > conversation about the status of QGIS, Qt6 and Wayland and I'm not having<br>>> > any luck.<br>>><br>>> What's the underlying need for this information?<br><br>... gather round folks, for a truly sorry tale! Here's the definitive(*) situation regarding QGIS and wayland.<br><br>- Qt 5 based applications do NOT work well under any wayland environment. There's fundamental broken functionality, and its functionality which QGIS requires. A good example is trying to drag a toolbar or dock panel -- you'll instantly "break" the application with non functional empty windows.<br>- This particular issue HAS been fixed in very recent Qt versions. Read all about it here: <a href="https://blog.david-redondo.de/kde/wayland/qt/2023/08/08/xdg-toplevel-drag.html" target="_blank">https://blog.david-redondo.de/kde/wayland/qt/2023/08/08/xdg-toplevel-drag.html</a> . BUT... this fix ONLY works if the desktop environment supports the fix. So you'll also need a very recent KDE release for this to work. Gnome, in typical Gnome fashion, have shown no interest in helping out other toolkits and implementing this new Wayland protocol and so Qt applications (even those built with Qt 6.6+) will still be broken. There's little hope on the horizon that Gnome will change their ways, so you'll also need to move to KDE and put Gnome in the past. 🤷<div></div></div></blockquote><div><br></div><div> It's disappointing to read this as there's clearly a disconnect between what e.g. QGIS developers are experiencing and what Fedora, Gentoo and maybe others are saying about Qt5 and Wayland.  For example, this on the Gentoo Wiki here <a href="https://wiki.gentoo.org/wiki/Wayland">https://wiki.gentoo.org/wiki/Wayland</a></div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">For Qt an additional package called <span style="white-space:nowrap" class="gmail-plainlinks" title="External link to https://packages.gentoo.org for the dev-qt/qtwayland package."><a rel="nofollow" class="external gmail-text" href="https://packages.gentoo.org/packages/dev-qt/qtwayland"><span style="font-family:monospace;font-size:95%;color:midnightblue">dev-qt/qtwayland</span></a><span style="color:grey;margin-left:0.1em;font-size:70%" class="gmail-fa gmail-fa-hdd-o gmail-fa-fw"></span></span>
 is required. In the Qt Wiki it says: "QtWayland is a Qt 5 module that 
wraps the functionality of Wayland. QtWayland is separated into a client
 and server side. The client side is the wayland platform plugin, and 
provides a way to run Qt applications as Wayland clients. The server 
side is the QtCompositor API, and allows users to write their own 
Wayland compositors."</blockquote><div><br></div><div>And this on Fedora here <a href="https://fedoraproject.org/wiki/Changes/Qt_Wayland_By_Default_On_Gnome">https://fedoraproject.org/wiki/Changes/Qt_Wayland_By_Default_On_Gnome</a></div><div><br></div><div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Qt Wayland plugin has been available for a long time, but it hasn't 
been in condition where it could be enabled by default. With Qt 5.12 the
 state of the Wayland plugin is much better and it's becoming more and 
more reliable. It now supports all the needed protocols and has been 
enabled by default for non-Gnome Wayland sessions.
With Qt Wayland on Gnome Wayland session we need to support CSD, it's 
actually the only way how decorations are going to work in Qt apps right
 now. Qt Wayland implements basic decorations, which really doesn't 
match Gnome Adwaita theme, therefore there are new CSD being implemented
 as part of QGnomePlatform.
</blockquote><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">To make Qt applications run natively on Wayland we need to modify Qt 5, specifically <b>qt5-qtbase</b>
 module, where we allow the Wayland plugin to be used also for Gnome 
sessions.  The new decorations from QGnomePlatform will be used 
automatically once they are fully implemented and updated in Fedora.
</blockquote><p>(the above dated 2019!!!)<br></p></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div>- So let's say you're running KDE, on a distro with a very recent Qt version. You'll still need a QGIS build based on Qt 6. That's a heavy work in progress at the moment. We're all ACTIVELY working toward that, but it's still some time away. You CAN build master versions and get a mostly working QGIS Qt6 build, so long as you don't require any Python support, that is!</div><div>- Ok, now lets assume you're on KDE, have recent Qt 6 library, have built QGIS master with Qt6 support and don't need python/plugins. Yay! Will everything work on Wayland? Well, not quite!.. There's still going to be broken functionality (such as the color picker not working outside of the QGIS application). There's also STILL fundamental missing bits in Wayland itself, such as proper restoring of Window locations. Every time QGIS opens a new dialog it'll just be thrown on some random screen at some random location. There's still no real progress toward that being fixed. Read about the sorry state of it here: <a href="https://gitlab.freedesktop.org/wayland/wayland-protocols/-/merge_requests/247" target="_blank">https://gitlab.freedesktop.org/wayland/wayland-protocols/-/merge_requests/247</a></div></div></blockquote><div><br></div><div>An exceptionally informative pull request.  I was particularly struck by this comment:</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"> Of course you could argue that all of these applications should be rewritten from the ground up, but especially in science this is not feasible - people will use X11 indefinitely rather than going to Wayland with a much degraded user experience.</blockquote><div><br></div><div>Maybe it's just me, but I have to think that the lack of a placement protocol (when X, Windows and OSX all support this) is a design mis-feature in Wayland, rather than a decision taken to guide the architecture of future desktop applications...</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><br></div><div>So yeah, not a happy situation. At least on the QGIS side we're making progress toward Qt 6 compatibility, and that's all we can really do from our end.</div></div></blockquote><div><br></div><div>Well as always, extreme thank-yous to all QGIS developers.  And again the information you provide here is very valuable at least to me, so thanks again for taking the time to write this! <br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><br></div><div>Nyall</div></div></blockquote><div><br></div><div>[previous stuff deleted]</div></div><br clear="all"><br><span class="gmail_signature_prefix">-- </span><br><div dir="ltr" class="gmail_signature"><div dir="ltr">Chris Hermansen · clhermansen "at" gmail "dot" com<br><br>C'est ma façon de parler.</div></div></div>