One of my personal adjustments to KWin is using the top right screen edge as a trigger for the Desktop Grid effect. With the switch to KWin on 5 this hasn’t worked for me any more as we don’t have code in place to transfer the old configuration to the new system.
Last week I had enough of it. It was breaking my workflow. So I had to do something about it and had the following possible options:
- Change the default: bad idea as we don’t want to use the upper right corner as that’s where maximized windows have their close button
- Carry a patch to change the default on my system: bad idea as that breaks my git workflow
- Just change the value in kwinrc
- Bring back the configuration module
As I considered just modifying the config value in kwinrc as not a durable solution I decided to go for bringing back the configuration module (KCM).
After a little bit of hacking and facing the problem that it used some not-yet ported library inside kde-workspace I got the code compiled and installed. But when I started it using kcmshell5 from kde-runtime I hit an assert.
So either my code was broken or kcmshell5. I didn’t really want to investigate the issue of the assert and decided to try the most obvious thing to me: use another implementation to test the kcm. And so I started to port systemsettings.
After about one hour of work I had systemsettings compiled, linked and installed and could start it, but alas my KCM was still hitting an assert. So what to do? Is it my KCM or is something more fundamentally broken which needs fixing in a different layer? How to test (I still didn’t want to investigate) so I started to port a few very simple KCMs from kde-workspace as systemsettings is at the moment still rather empty. And look there, they worked in both kcmshell5 and in systemsettings.
So I started to port another KWin module and that one also hit the same assert. After some discussion on IRC with Marco I learnt that he also hit the same assert in another KCM which means that there was a pattern. And finally I started to investigate. Very soon I had a testcase with a slightly reduced KCM which I could get to hit the assert with adding one additional element to the ui file. A good start to find a workaround and now my KCM loads in systemsettings and I have my screenedge back:
Screenshot is featuring both systemsettings and KWin using Qt 5 and KDE Frameworks 5!
Now all I need to do is to extract my minimum “make it crash” code as a testcase and submit a bug report to Qt.