change the aspect ratio for window resize