Linux - Desktop This forum is for the discussion of all Linux Software used in a desktop context. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
06-16-2020, 12:43 PM
|
#1
|
Senior Member
Registered: Dec 2003
Distribution: Mint 20.1 on workstation, Debian 11 on servers
Posts: 1,350
Rep:
|
How do I force every single GUI element (windows, dialogs, menus etc) to ALWAYS open on the screen it was launched from?
This is one of my absolute worse pet peves with multi monitor setups and it seems no OS maker can get this right. Windows is just as terrible.
Say you are in a program, and you click on something that launches a dialog, every now and then the dialog will end up on another monitor instead of the one I'm actually working off of. Or worse, launching a new application from a desktop icon or start menu, and the window goes in some random place instead of the monitor I'm working on. I've even seen instances where a right click context menu sends the menu on another screen.
How do I fix this permanently and globally? There's too much "it depends" when it comes to this, and I want to get rid of that. I want to make it global. There are window rules you can set in KDE but they seem to only be honoured at random.
Right now it's happening In Firefox where I have a popup ending on on another screen. It's VERY irritating, especially when I don't have access to that screen. I'm working from home and right now that screen is toggled to the work PC. If I change it, it will send all those windows all over the place making a huge mess on my work PC. (a known Windows issue with Displayport) so that is not an option.
So how do I force applications to always open dialogs on the same monitor it was launched from?
If it matters I'm running Kubuntu 20.04.
|
|
|
06-16-2020, 01:53 PM
|
#2
|
LQ Addict
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 24,644
|
you can't fix it on anywhere but your own apps. That is a very interesting question and I think it was never ever explained. There are a lot of different display geometry definitions available (for current desktop, current monitor, virtual display, current window ....) Mostly they are mixed and improperly used.
If you want to force an application to use a given (your preferred) algorithm you need to implement it and modify the source code of it.
by the way I have almost forgotten: some of them have [tricky] config files to make it even more difficult.
Last edited by pan64; 06-16-2020 at 01:54 PM.
|
|
|
06-16-2020, 03:21 PM
|
#3
|
Senior Member
Registered: Dec 2003
Distribution: Mint 20.1 on workstation, Debian 11 on servers
Posts: 1,350
Original Poster
Rep:
|
Sounds like a mess then, they really need to fix that. Modifying source code of apps is a logistical nightmare, because it means I either forfeit updates, or have to change it every time there is an update. Not to mention the fact that it has to be done on a per app basis.
Is there a way to create some kind of virtual environment per monitor where when an app is opened from it, it simply does not even see the other monitors and think there is just one? Closest I can think of is running a full screen VM in each monitor and then doing everything within the VM, but that feels really dirty, hopefully there is a better way. I've tried to set each screen on a separate X11 session before thinking it would do it, but I still had apps open on wrong one.
|
|
|
06-17-2020, 01:07 AM
|
#4
|
LQ Addict
Registered: Dec 2013
Posts: 19,872
|
It's not really a mess.
Window managers and desktop environments have settings that define where new windows are opened; in some cases extreme fine-tuning is possible (like, open windows with firefox class & dialog role always on desktop 3).
If you use Xorg for your GUI, you could test various windows with and see what sort of attributes they have, then see what sort of rules your WM/DE allows for that.
One thing that's difficult in your request: there's often a substantial delay between the time an application is launched and the time it maps its first window. Only the second event is recognised by your WM/DE.
|
|
|
06-17-2020, 08:19 PM
|
#5
|
LQ Guru
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Ubuntu MATE, Mageia, and whatever VMs I happen to be playing with
Posts: 20,015
|
Since you are using Kubuntu, I'm guessing you are using the Plasma desktop.
This article explains how to get an application to remember its window position in the Plasma desktop, but I have no idea and no way of testing whether it remember which monitor in a multi-monitor setup: https://websetnet.net/plasma-secrets...ndow-position/
|
|
|
06-17-2020, 08:38 PM
|
#6
|
Senior Member
Registered: Dec 2003
Distribution: Mint 20.1 on workstation, Debian 11 on servers
Posts: 1,350
Original Poster
Rep:
|
Yeah I have tried the rules, problem is, it seems some applications override it. I'm looking for a way that is more guaranteed. Virtualbox is another offender, no matter what I do it always opens on the top monitor when I want it to open on the primary bottom monitor. In fact now it's opening in a void that does not even exist so I can't access it.
Last edited by Red Squirrel; 06-17-2020 at 08:41 PM.
|
|
|
All times are GMT -5. The time now is 08:45 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|