Announcement

Collapse
No announcement yet.

How to get windows to open on the primary display by default?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    [PLASMA 5] How to get windows to open on the primary display by default?

    Hi everyone,
    my laptop is plugged to an external screen and I would have expected new windows to open on the primary display - which is my laptop screen.
    Instead, most (if not all) applications open their window on my external display, which is not what I want.
    Could it be due to the "Configure Special Window Settings..." option of every application remembering its last display screen?... I often use to set windows' position and size to be remembered by Plasma for future launches, but I never asked the screen itself to be remembered...
    I searched a bit through Plasma's System Settings and couldn't find any related configuration telling Plasma to use screen A or B to open new windows on by default...
    Thanks in advance for any information / rule to know on this topic.

    #2
    Hi Valdo,

    That's where you set it, "Configure Special Window Settings..." or "Configure Special Application Settings...", you can specify Screen 1, Screen 2 etc.

    I have long used the "Apply initially" setting but it no longer seems to work for some applications since 20.04.

    Nick
    Kubuntu 20.04(AMD64)/KDE 5

    Comment


      #3
      I would love to see a fix for that too. Even with the settings set, I find some apps still behave wrongly. I have it set to open where cursor is. For example in kdenlive if it's maximized on the main screen, the right click menu for tracks ends up on the other screen. Also had it happen with Kicad, but it seems to remember after. Still kind of annoying since when using a new app you don't know where it will end up. Would be nice if it would always open on the same screen it was launched from 100% of the time.

      It seems all OSes are bad at this too, Windows is very terrible at it. In Linux it's more bearable as it's not too bad most of the time.

      I find the only way to fix this (in Linux or Windows) is to have the primary monitor on the most left with all the other monitors to the right, but that's not always physically feasible. For example in my setup my primary is in front of me and secondary is directly on top. It's like if it often chooses the first monitor starting from top right.

      Comment


        #4
        I've only got one screen, but ...
        Have you guys checked out "Window Rules"? Maybe you could have a rule that matched very generally, and applies initially, and species the screen. I sometimes use a rule to put things on another activity or desktop.
        Regards, John Little

        Comment


          #5
          Thanks both for the feedback, for now I've filed a KDE bug report.
          Kubuntu 20.04(AMD64)/KDE 5

          Comment


            #6
            It's still early to tell... but I MAY have figured something out. In the windows rules, on the "window matching" tab, there's an option for "detecth window properties" where you can add a delay. If you add a 1 sec delay, it may fix it. I think what might be happening is depending on how each specific app is written, the window properties might get filled in after the window is drawn, if that is the case the rules won't work and the window will go wherever the hell it wants - usually on the wrong screen.

            Still very early to tell if this works though, but I will report back.

            I would still prefer if I can do something universal that just works on *ALL* windows but nothing seems to work for that, it's on a per dialog basis. So as I run into a window that does not open properly I have to add a new rule. Hard to tell if these are working though, it seems lot of dialogs in kdenlive are very stubborn and still go to wrong monitor, same with context menus, you right click and instead of menu opening under cursor it just goes on the other screen. Only seems to do it if it's full screen. Seen it happen with other apps too - even in Windows. Seems to be a widespread problem across all OSes with random apps.

            Comment


              #7
              Thanks @Red Squirrel, I've done a quick test and this looks promising!
              Kubuntu 20.04(AMD64)/KDE 5

              Comment


                #8
                Originally posted by Valdo View Post
                Hi everyone,
                my laptop is plugged to an external screen and I would have expected new windows to open on the primary display - which is my laptop screen.
                Instead, most (if not all) applications open their window on my external display, which is not what I want.
                Could it be due to the "Configure Special Window Settings..." option of every application remembering its last display screen?... I often use to set windows' position and size to be remembered by Plasma for future launches, but I never asked the screen itself to be remembered...
                I searched a bit through Plasma's System Settings and couldn't find any related configuration telling Plasma to use screen A or B to open new windows on by default...
                Thanks in advance for any information / rule to know on this topic.
                Not exactly what you asked for, but this gave me a descent workaround with which I can live with:
                • Open the window that opens where you DON'T want it to.
                • Move it where you wish it to open.
                • Rightclick the titlebar of the particular window.
                • Select "More actions" -> "Configure special window settings"
                • (read the popup and click "ok")
                • On "Size & Position" tab, select "Position" and from the dropdown menu next to it, select "Remember"
                • Click "OK"

                Next time it opens to where it now was placed.
                Unfortunately this must be done separately to all misbehaving windows. I only had one (mediainfo).

                Comment


                  #9
                  Thanks @karsta I'll give this a go!
                  Kubuntu 20.04(AMD64)/KDE 5

                  Comment

                  Working...
                  X