toglia3d
11th June 2010, 00:33
I'm using official nvidia drivers with twin view and I noticed sizes are not right.
QDesktopWidget desktop;
int w0 = desktop.screen(0)->width();
int h0 = desktop.screen(0)->height();
int w1 = desktop.screen(1)->width();
int h1 = desktop.screen(1)->height();
std::cout << desktop.numScreens() << std::endl;
std::cout << w0 << " : " << h0 << std::endl;
std::cout << w1 << " : " << h1 << std::endl;
output:
2
3600 : 1200
3600 : 1200
My monitor configuration is 1920 1200 and 1680 1050. Obviously the sizes are merged. Is this a normal behavior? How can I get independent sizes?
This is somewhat of a problem since I wanted to fit the window in the center on the first screen...
Thanks
QDesktopWidget desktop;
int w0 = desktop.screen(0)->width();
int h0 = desktop.screen(0)->height();
int w1 = desktop.screen(1)->width();
int h1 = desktop.screen(1)->height();
std::cout << desktop.numScreens() << std::endl;
std::cout << w0 << " : " << h0 << std::endl;
std::cout << w1 << " : " << h1 << std::endl;
output:
2
3600 : 1200
3600 : 1200
My monitor configuration is 1920 1200 and 1680 1050. Obviously the sizes are merged. Is this a normal behavior? How can I get independent sizes?
This is somewhat of a problem since I wanted to fit the window in the center on the first screen...
Thanks