Resize before viewer