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?
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?
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:
compizconfig-settings-manager
package) and go to the General Options plugin.Compiz should now treat your multi-monitor setup as one big output.
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.
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...
I wanted to elaborate on @codlord's great suggestion:
Mapping
xdotool getactivewindow windowsize 110% 110%
to a keyboard shortcut did exactly the trick (i.e., under Settings) - this should work regardless of the desktop manager (Gnome, Cinnamon, XFCE, etc.).xdotool
via:sudo apt install xdotool
man xdotool
was very helpful and contains a lot of other neat ideas.