kwin-scripts / kwin-tiling

Tiling script for kwin
GNU General Public License v2.0
1.1k stars 68 forks source link

using floaters in config results in strange tiling behaviour #240

Closed tabroughton closed 3 years ago

tabroughton commented 3 years ago

to get QJackCtl floating and came across this.

kwin-tiling/contents/code/ignored.js
Line 68 in a240b43
 || floaters.indexOf(client.resourceName.toString()) > -1 

in kwinrc under the tiling config I added floating=QJackCtl which worked but it has resulted in strange behaviour. I now often get windows opening for other programms (like add/remove software) floating in the centre of the scree, I get other windows full screen underneath other tiled applications, and I seem to get some other strange behaviours.

If I manually fiddle with the windows that are troublesome when they open then I can get them to tile properly but on opening they are usually misbehaving.

is it because I'm using something untested? or is it because I'm using the floating config wrongly?

faho commented 3 years ago
  1. The configuration entry is called "floaters", not "floating"
  2. Any particular reason you're editing the config file directly instead of going via the menu?
  3. Any other scripts or anything?
tabroughton commented 3 years ago

yes sorry my typo - i do in fact have "floaters" in the config.

[Script-kwin-script-tiling]
floaters=QjackCtl
noBorder=true
placement=2

When I open the menu I can see it has populated the form field for "Exluded window classes" with QJackCtl so I assume this is correct.

An example of the issue I'm getting is say if I have thunderbird open full screen and I open an attachment in Okular (pdf) then the Okular will open tiled to half the screen but thunderbird will remain full screen underneath it. If I then click on thunderbird in the taskbar/manager the window sorts itself out and tiles as expected.

tabroughton commented 3 years ago

I have just removed the line from the kwinrc and logged back in and the issues have gone away.

I have entered "QJackCtl" into the menu this time and saved, and then logged back in and the issues are back.

Another example is when I open the "system settings" if I have a tiled screen already then the system settings are overlaid on the right most side over the centre. (ie. I have emacs on left half, firefox in right half, when I open system settings it's overlaid in the centre of the firefox window taking approx 1/3 of the screen height) - I wish there was an easy way to attach an image to show you.

One more bit of detail is that I'm using 2 monitors, in this scenario described here I have Konsole on screen2 full screen, and emacs and firefox half and half on screen 2. I have tiling set to "half".

are there any other tests or details I can send?

faho commented 3 years ago

Another example is when I open the "system settings" if I have a tiled screen already then the system settings are overlaid on the right most side over the centre

Yeah, system settings has a massive minimum size, and unfortunately kwin doesn't want us to go below it. I'm afraid that's unfixable on our end.

I wish there was an easy way to attach an image to show you.

You can just attach a file by dragging & dropping - it says so at the bottom of the comment box. Click on that and it'll open a file picker.

faho commented 3 years ago

Okay, I've just tested with your config, I can't reproduce it.

You're going to have to investigate some more. It's possible you have an old kwin version that has a bug, or you're running on wayland and that has a bug, or your system configuration is weird.

Adding floaters is well-tested and typically works, so there's something else going on here.

tabroughton commented 3 years ago

I'll close this, and put it down to user error. I have just spent another hour or so testing various settings and combinations etc and everything was going wrong. I'll put it down to manually updating the kwinrc, I must have edited something by accident, luckily I store it using YADM - I restored, put the application name into the menu this time and everything has been fine.

tabroughton commented 3 years ago

@faho thank you for quick response - I really appreciate it and I really appreciate kwin-tiling too