fixed the fit of the main window