kwin-scripts / kwin-tiling

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

Plasma 5 support #30

Closed willprice closed 7 years ago

willprice commented 10 years ago

Hi,

I've tried installing the script under the new Plasma 5 desktop but can't seem to get it working. I appreciate this isn't a very helpful bug report as it contains no information whatsoever, but I'm not sure what is relevant. I'd be happy to help with alpha/beta testing on plasma 5.

insidewhy commented 8 years ago

I fixed keyboard shortcuts in QML now ;) Could anyone tell me if it's possible to remove/update a kwinscript? I've tried the -u/-r options to plasmapkg2 but they seem broken. How do you guys handle it when developing kwin-tiling?

v3ss0n commented 8 years ago

Hiw.Can you share us the fix??

Hi-Angel commented 8 years ago

@v3ss0n it's here https://bugs.kde.org/show_bug.cgi?id=340225#c22

faho commented 8 years ago

How do you guys handle it when developing kwin-tiling?

I actually symlink the script install dir (~/.local/share/kwin/scripts/kwin-script-tiling) to the git repo.

insidewhy commented 8 years ago

I see, symlink and kwin --replace to reload. I'll try and get plasmapkg2 to work properly then. After that I can work on some of your other issues, if you could let me know which are most important I'll get to them first.

faho commented 8 years ago

After that I can work on some of your other issues, if you could let me know which are most important I'll get to them first.

Woohoo, thanks!

I'm assuming you mean upstream kwin issues. If so, the one that bugs me the most is https://bugs.kde.org/show_bug.cgi?id=341195, which is #6 here (under certain circumstances, we can cause clients to not update graphically anymore).

After that, there's https://bugs.kde.org/show_bug.cgi?id=340125, which might be much smaller and is more of a minor annoyance for developing this thing.

insidewhy commented 8 years ago

https://bugs.kde.org/show_bug.cgi?id=341195 could be difficult to fix, but I can easily fix https://bugs.kde.org/show_bug.cgi?id=340125

insidewhy commented 8 years ago

@faho btw could you explain how inheritance is broken? You mean as in EcmaScript inheritance via childClass.prototype = Object.create(parentClass.prototype) (or maybe QML doesn't support Object.create and you need the worse: childClass.prototype = new parentClass?) Neither of those?

faho commented 8 years ago

@ohjames: That one was a wrong assumption on my part. KWin 5 is a bit stricter when it comes to includes, and I was doing the latter when I hadn't included the parent directly.

insidewhy commented 8 years ago

I see. Do you know if ES5.1 methods like Object.create are available from declarativescript? I'm pretty sure their engine uses a recentish version of v8 and should do, but I couldn't find Object.create in kwin-tiling's source so I wasn't sure if it is possible. BTW I've responded to all of the code review items so the registerShortcut patch should hopefully be pulled soon. My clone in github has it in case you want to try it out.

faho commented 8 years ago

Do you know if ES5.1 methods like Object.create are available from declarativescript?

Nope. To be honest that's the first I've heard of them. I'm not much of a web guy.

BTW I've responded to all of the code review items so the registerShortcut patch should hopefully be pulled soon.

Very nice!

insidewhy commented 8 years ago

I've fixed https://bugs.kde.org/show_bug.cgi?id=340125 also now. Without it you can watch for new clients being added and cache them that way, but not get the existing list of clients?

faho commented 8 years ago

Without it you can watch for new clients being added and cache them that way, but not get the existing list of clients?

Yeah. Which is why it's annoying for development. When you restart kwin, it won't automatically tile existing clients.

For normal use, it's not really important.

insidewhy commented 7 years ago

I find the feature really useful, I'm using it in kwin window switch already to simplify switching between windows... without it I'd have to watch for windows to open.

faho commented 7 years ago

So, current git master basically works on Plasma 5. It's installable since a kind soul uploaded it to store.kde.org.

My current plan is to clean it up a bit again (I've already fixed some shortcut functions that were broken for P5), find some way to configure excludes - #64, and then make a first actual plasma 5 release. It should be widespread enough now.

v3ss0n commented 7 years ago

thank you very much for the great work!

pdf commented 7 years ago

After fighting to install this for a while, I've discovered that support for installing kwin script packages is currently broken in 5.8 (at least on Arch, 5.8.5/5.30.0), and won't be fixed until 5.9 is released by the looks: https://bugs.kde.org/show_bug.cgi?id=374766

I tried manually stuffing things into ~/.local/share/kwin/scripts and ~/.local/share/kservices5, but whilst I could get the plugin to show up in the list of scripts, edit the config, etc, the script does not appear to run.

BTW, plasmapkg2 is apparently deprecated and replaced with kpackagetool5 (on my Arch system, plasmapkg2 appears to be a thin wrapper that just calls kpackagetool5).

faho commented 7 years ago

This has been fixed for a while now.