From 7a85b77f502e211033456c936e53bf8c595672a3 Mon Sep 17 00:00:00 2001 From: Salvo 'LtWorf' Tomaselli Date: Fri, 11 Sep 2015 12:41:33 +0200 Subject: [PATCH] Save state of splitter in GUI The splitters are not stored as part of the window's state, so store it separately. --- relational_gui/guihandler.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/relational_gui/guihandler.py b/relational_gui/guihandler.py index 6039fd2..ee41b6e 100644 --- a/relational_gui/guihandler.py +++ b/relational_gui/guihandler.py @@ -260,6 +260,7 @@ class relForm(QtWidgets.QMainWindow): def save_settings(self): self.settings.setValue('maingui/geometry', self.saveGeometry()) self.settings.setValue('maingui/windowState', self.saveState()) + self.settings.setValue('maingui/splitter', self.ui.splitter.saveState()) self.settings.setValue('maingui/relations', self.user_interface.session_dump()) def restore_settings(self): @@ -272,6 +273,7 @@ class relForm(QtWidgets.QMainWindow): try: self.restoreGeometry(self.settings.value('maingui/geometry')) self.restoreState(self.settings.value('maingui/windowState')) + self.ui.splitter.restoreState(self.settings.value('maingui/splitter')) except: pass