I'm trying to make a Qt app cover both monitor screens in a dual screen setup. The idea is to simply use

Qt Code:
  1. move(0, 0);
  2. resize(2*1920, 1080);
To copy to clipboard, switch view to plain text mode 

calls to the main window, where each of my screens is of 1920x1080 resolution.

On Windows, this achieves the desired result, but on Linux, the size of the window is always limited to a single screen.

I wonder how to solve this issue?

xdpyinfo reports the combined screen size:

Qt Code:
  1. $ xdpyinfo | grep dimensions
  2. dimensions: 3840x1080 pixels (1016x286 millimeters)
To copy to clipboard, switch view to plain text mode 

while for the following, I get:

Qt Code:
  1. std::cout << "screen 0: " << QApplication::desktop()->screenGeometry(0).width() << std::endl;
  2. std::cout << "max size: " << view.maximumSize().width() << std::endl;
  3. std::cout << "max viewport: " << view.maximumViewportSize().width() << std::endl;
To copy to clipboard, switch view to plain text mode 

Qt Code:
  1. screen 0: 1920
  2. max size: 16777215
  3. max viewport: 640
To copy to clipboard, switch view to plain text mode 

this is on ubuntu 14.04 64 bit, with an nvidia GTX760 card, using the latest nvidia factory drivers