Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Always Open on Active Screen] Windows do not actually open on active screen #2

Open
Slater91 opened this issue Nov 8, 2021 · 10 comments
Labels
status:resolved This issue has been resolved type:help Help is needed to make things work

Comments

@Slater91
Copy link

Slater91 commented Nov 8, 2021

Hello! I just installed the "Always open on active screen" script. Unfortunately it does not work. If I start an application, it still opens on whatever screen it pleases instead of the one the cursor is in. I have tried restarting KWin, but to no avail. It does work, however, if I click on the desktop first.

I am using two screens, both with the same resolution and vertically arranged, on X11.

The base system is KDE Neon with Plasma 5.23.2, KDE Frameworks 5.87.0 and Qt 5.15.3.

@nclarius nclarius added the type:bug Something isn't working label Nov 8, 2021
@nclarius
Copy link
Owner

nclarius commented Nov 8, 2021

Off the top of my head I don't know what could cause this, I assume some window behavior setting is incompatible with the script but I couldn't identify it in my tests.

Could you please tell me what you have in System Settings > Window Management > Window Behavior for the following settings:

  • Focus > Window activation policy
  • Focus > Multiscreen behavior > Active screen follows mouse
  • Focus > Multiscreen behavior > Separate screen focus (this option shows only when multiple screens are currently connected)
  • Advanced > Window placement
  • Advanced > Window placement > Allow apps to remember the position of their windows

Also, do you perhaps have any window rules (System Settings > Window Management > Window Rules) or other KWin scripts (System Settings > Window Management > KWin Scripts) that might override the screen preference?

And did logging out and in again not make the script work either?

@Slater91
Copy link
Author

Slater91 commented Nov 8, 2021

A-ha, I think I got it. I had "active screen follows mouse" disabled. Enabling it does the trick. I did not know the option was there at all, to be honest! I would suggest including this in the readme for further clarity.

Thank you for your kind help and for developing this great script, it's going to be a game changer for me! Have a great day! :)

@Slater91 Slater91 closed this as completed Nov 8, 2021
@nclarius
Copy link
Owner

nclarius commented Nov 8, 2021

Yes, of course. Thanks for making me aware of it!

Glad to hear you like the script, and thank you for the kind words. If you want to help spread the word you can leave a review in the KDE store.

@nclarius nclarius added type:help Help is needed to make things work status:resolved This issue has been resolved and removed type:bug Something isn't working labels Nov 8, 2021
@nclarius nclarius changed the title Windows do not actually open on active screen [Always Open on Active Screen] Windows do not actually open on active screen Nov 15, 2021
@xalt7x
Copy link

xalt7x commented Nov 27, 2021

@nclarius

Focus > Multiscreen behavior > Active screen follows mouse

I have another example. Without this option GIMP 2.10.28 shows splash screen on a wrong monitor but after that actual window is placed correctly.
Could you please mention it in a readme somewhere? And "this option shows only when multiple screens are currently connected" as well.
It could also be set at ~/.config/kwinrc

[Windows]
ActiveMouseScreen=true

Anyway, thanks for making KDE Plasma better! 👍
"Always Open on Primary Screen" works out of the box but I guess most users would prefer this ("Always Open on Active Screen") script.

@nclarius
Copy link
Owner

nclarius commented Nov 28, 2021

@Alt37 That Active screen follows mouse has to be enabled already was in the readme, or what do you mean?
That the option is only visible when several monitors are connected and the alternative route via the config file I just added, thanks for pointing it out.

@xalt7x
Copy link

xalt7x commented Nov 28, 2021

@nclarius
Ah, sorry, I missed that it's actually on the github readme. Could you put this information at store.kde.org? Users which find this script via "Get New Scripts" need to now that as well.
Thanks.

@nclarius
Copy link
Owner

Done.

@Slater91
Copy link
Author

Slater91 commented Apr 30, 2023

Hello. I am reopening this issue as I can't get windows to open on the active screen at all on my desktop, despite trying all possible settings. I am using Plasma with X11. I can't really find any pattern to the opening on the wrong screen, it seems to be entirely random.

I have checked the settings on my laptop, where the issue is not present, and they appear to be exactly the same. The laptop has version 2.1 installed and I tried using that as well on my desktop, with no luck however. I have run out of ideas on how to find the source of this problem.

@Slater91 Slater91 reopened this Apr 30, 2023
@nclarius
Copy link
Owner

nclarius commented May 1, 2023

Do you have the apps remembering positions feature turned off?

@Slater91
Copy link
Author

Sorry, I completely missed your message! Yes, it is turned off, though that introduces other issues (e.g. the size is reset every time I close and re-open some apps, though I guess that's a bug in KWin).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status:resolved This issue has been resolved type:help Help is needed to make things work
Projects
None yet
Development

No branches or pull requests

3 participants