set preferred size of main window