I usually save QMainWindow state with saveState() in QMainWindow::closeEvent(), as pretty much all the examples suggest.
But if I have floating dock widgets and I exit the app then during the closeEvent the dock widget is usually (but not always) hidden, so saveState() records it as not visible, which means it's hidden when the app is restarted. macOS Sierra, same behaviour on both Qt 5.9.0 and 5.11.0. Is there a better point in the quit process to hook to save that state? Cheers, Steve _______________________________________________ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest