auto get screen resolution, if none is given