40

It's easy to maximise windows on a single monitor (press the maximise button, or drag the window titlebar to the top of the screen).

How can I maximise a window so that it takes up two screens?

27
+550

This is possible by manually telling Compiz the screen output size, using the combined resolution of the two monitors. That's where the limitation kicks in: both displays need to have the same (vertical) resolution for this to make sense (else you'd end up with cut off content on the smaller screen or dead space on the bigger one).

For example, with two monitors with 1920x1080 resolution, you'd:

  • Open the CompizConfig Settings Manager (if you haven't already, install the compizconfig-settings-manager package) and go to the General Options plugin.
  • On the Display Settings tab, disable the Detect Outputs checkbox, select the 640x480+0+0 entry and click on Edit,
  • Now change this to 3840x1080+0+0 and hit close.

enter image description here

Compiz should now treat your multi-monitor setup as one big output.

| improve this answer | |
  • 7
    That helps, thanks! However it changes the behavior of double click on any window. Ideally I would to be able to tell that this time I want a normal maximisation and this other time I prefer a double one. – RockScience Apr 14 '14 at 11:20
  • I'm wondering aobut that, too. Is it possible to have this on a per-window basis? – Ingo Apr 17 '14 at 11:00
  • 2
    This just treats your monitors as a single display. How about the ability to keep independent displays, and span a window across them with a shortcut? Pretty much the same way win7 does. – nullsteph Jan 15 '15 at 3:56
  • This also works for Chrome in kiosk mode, very nice. – Mateo Apr 7 '17 at 17:05
  • 2
    Compiz/Unity will be soon deprecated. An answer for Gnome 3 is needed. – Waldemar Wosiński Feb 13 '18 at 8:38
3

Drag your window until it snaps to one edge of first monitor then resize it all the way to the other end of the secondary monitor. It is not real window maximization, but it displays window content wider or higher if monitors are positioned one above other.

| improve this answer | |
  • If it doesn't have a keyboard shortcut, it won't be used. – Tomislav Nakic-Alfirevic Apr 26 '17 at 9:26
  • 1
    @TomislavNakic-Alfirevic, actually I use this method quite often when I'm coding and need to see several source codes at the same time. I don't care a few seconds needed to use this method, since I'm gonna work in that way for some hour. – Enrico Maria De Angelis Apr 19 '18 at 13:11
  • 2
    @EnricoMariaDeAngelis I could have made a fine point saying "most people won't use it without a shortcut" instead of flat out "won't be used", but my point was that when people manipulate windows hundreds of times a day, not having a keyboard shortcut for a particular kind of manipulation will limit the user base to a very small fraction of what it otherwise would have been because it's much less useful. Sure, I stretched windows across 2 screens, but I did it less than once a year. I would have done it more often if there was a shortcut and I believe many others would, too. – Tomislav Nakic-Alfirevic Apr 25 '18 at 9:12
0

You could use xdotool and setup shortcuts/scripts.

I just did a quick test on a window and in my multi-monitor environment this made a window full screen across both monitors:

xdotool search --name "Untitled"

xdotool windowmove 96469240 -26 4

xdotool windowsize 96469240 110% 110%

I got the -26 4 starting coordinates by putting at top-left and xdotool getwindowgeometry 96469240

And not sure why 100% was not stretching to actually 100% of the monitors...

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.