Summary: | wayland: krunner position no longer follows window rules and can't be set to "under mouse" | ||
---|---|---|---|
Product: | [Plasma] krunner | Reporter: | Duncan <1i5t5.duncan> |
Component: | general | Assignee: | Alexander Lohnau <alexander.lohnau> |
Status: | RESOLVED DUPLICATE | ||
Severity: | normal | CC: | aldo-public, ashark, isma.af, kishore96, mail, nate, plasma-bugs |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Gentoo Packages | ||
OS: | Other | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: | |||
Attachments: | hackpatch: krunner to bottom-right of its default screen |
Description
Duncan
2020-11-16 01:49:13 UTC
Created attachment 133730 [details]
hackpatch: krunner to bottom-right of its default screen
This is the worst paper-cut bug remaining from my switch to wayland, that I haven't at least hacked around... until this hack-patch anyway.
Not being a dev I haven't been able to trace down what in (presumably) kwin is forcing it to ignore window rules for krunner (I did try patching something that looked like the possible culprit and ended up spending several hours trying to recover after the experiment went horribly wrong and screwed up my plasma config and getting it back wasn't as easy as simply replacing plasma-org.kde.plasma.desktop-appletsrc with a backup), but...
This at least forces placement to the bottom-right of the screen it defaults to, making it easier to use as it's at least /close/ to my normal focus at the bottom-left of the screen just to the right.
Actually KRunner is supposed to follow the mouse, but on wayland there is currently no way of getting the cursor position. Also there is no primary monitor concept, which could be a workaround. (In reply to Alexander Lohnau from comment #2) > Actually KRunner is supposed to follow the mouse, but on wayland there is > currently no way of getting the cursor position. Also there is no primary > monitor concept, which could be a workaround. I'd read about wayland lacking the primary monitor concept in other bugs. Unfortunate. As for follows-mouse, kwin as compositor has to know the mouse position, correct? And it can enforce under-mouse on other windows -- I have a kwin window placement rule that does just that for the troublesome appmenu-in-titltebar menu-popup, which otherwise follows the general least overlapping rule and ends up way across the screen -- troublesome when you have focus-follows mouse set as you can't get there without changing focus away from the window whose menu you are trying to work with. Unfortunately, apparently krunner is a plasmashell window, and plasmashell windows get to override kwin's window rules, even user-set ones! (I've seen that mentioned in other bugs.) That explains why krunner ignores the under-mouse window-rule I've set for it. If I could just find out where that ignore was coded I could try to hack-patch that out and my krunner window rule would work as it should. But so far that has eluded me. Found a similar bug about yakuake: Bug 411681 If that gets solved, probably the method of getting screen with mouse could be used here as well. Another side effect of this bug: when exiting krunner, the focus doesn't necessarily go back to the window that previously had it. Instead it goes to the active window of the left screen, which is particularly frustrating when the screen you use as primary is on the right hand side. This behavior probably deserves its own bug. This bug was invisible when krunner used to correctly appear on current screen. But even if #429177 is fixed, the focus bug could come back when screen placement options will be implemented in krunner. By the way, this focus issue also affects Yakuake. Duplicate of bug 427069 ? (In reply to Kishore Gopalakrishnan from comment #7) > Duplicate of bug 427069 ? Seems to be. Thanks. *** This bug has been marked as a duplicate of bug 427069 *** |