Set screen size in docker image

this topic may help:

it is not enough just to set the browser windows size via capabilities or through the driver methods, but the virtual display size has to be set too, using xfvb-run. without specified size i think it will default to 800 x 600

however, xfvb is needed when using normal browser. with the headless one, the browser size can be set though the driver. WebUI.SetViewPortSize should do the trick, it was a bug in 6.something but according to @Zarashima the issue was fixed.

1 Like