Added option to set viewportSize