SeleniumHQ / selenium-google-code-issue-archive

Archive, please see main selenium repo
https://github.com/seleniumhq/selenium
345 stars 195 forks source link

Setting browser's size results in wrong size when used with Firefox on Windows8 #6594

Closed lukeis closed 8 years ago

lukeis commented 8 years ago

Originally reported on Google Code with ID 6594


What steps will reproduce the problem?
1. Go to Windows8 machine
2. Use FirefoxDriver 
3. Set Browser's size to 1024X768

What is the expected output?
Firefox is opened with (frame) size 1024X768

What do you see instead?
Firefox is opened with (frame) size 1280X960

Selenium version: Not known yet
OS: Windows8
Browser: Firefox 
Browser version: Not known yet

I run the same test on Chrome and Firefox, resulting print screens are:
Firefox: http://i.imgur.com/OrnHDyQ.png
Chrome: http://i.imgur.com/yplkPrs.png

Note that the difference in size is 25%, where maybe it's not a coincidence that the
window's devicePixelRatio is set to 1.25 on Firefox in windows8 (as opposed to 1 on
windows7, where everything is working great).

Cheers,
Hope this helps,
Oren Rubin

Reported by oren.rubin@applitools.com on 2013-11-19 17:25:38

lukeis commented 8 years ago
After checking the display settings, I've noticed that the options "Change the size
of all items" is set to "Medium - 125% (default)", which explains this behavior.

Reported by oren.rubin@applitools.com on 2013-11-20 08:53:35

lukeis commented 8 years ago
It seems that it's not a bug.
Selenium screenshot stays intact (100%) though the user actually sees enlarged website.
This scenario is still important since those who take screenshots starts by setting
the browser size to some deterministic value.
On the same physical machine, using it on windows 8 (rather then 7) can now fail since
it can't fit anymore (window cannot grow larger than screen viewport).

Hope this helps others,
Cheers,
Oren Rubin

Reported by oren.rubin@applitools.com on 2013-11-20 09:04:00

lukeis commented 8 years ago

Reported by barancev on 2013-11-20 10:11:30

lukeis commented 8 years ago

Reported by barancev on 2015-03-16 06:47:23

lukeis commented 8 years ago

Reported by luke.semerau on 2015-09-17 18:18:13