Did you know ... Search Documentation:
window->_compute_desired_size