Fix to preferences dialog for autofit