From 8bc07171ff74818d8b50ed6a551ce66ee55d2fcc Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Fri, 9 Jul 2021 08:29:28 +0530 Subject: [PATCH] Workaround Qt bug that broke restoring of dock widget states in the editor --- src/calibre/gui2/tweak_book/ui.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/calibre/gui2/tweak_book/ui.py b/src/calibre/gui2/tweak_book/ui.py index 05f7bc351c..eb54946c9b 100644 --- a/src/calibre/gui2/tweak_book/ui.py +++ b/src/calibre/gui2/tweak_book/ui.py @@ -376,8 +376,8 @@ class Main(MainWindow): g = QApplication.instance().desktop().availableGeometry(self) self.resize(g.width()-50, g.height()-50) - self.restore_state() self.apply_settings() + QTimer.singleShot(0, self.restore_state) def apply_settings(self): self.keyboard.finalize()