diff --git a/CHANGELOG b/CHANGELOG
index 4ec4e3f..079c336 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -5,6 +5,10 @@ Two empty lines before the next entry.
External contributors notice at the end of the line: (LastName, FirstName / nick)
## 2022-01-15 0.3.1
+Option in Control menu to split the session view between horizontally and vertically
+The session list now dynamically expands to the needed with.
+Better log messages
+Fix regression and workarounds for crashes introduced by a recent PyQt update.
This CHANGELOG is now available through the programs help menu directly.
diff --git a/engine/start.py b/engine/start.py
index a428746..ac38502 100644
--- a/engine/start.py
+++ b/engine/start.py
@@ -58,10 +58,10 @@ args = parser.parse_args()
import logging
if args.verbose: #development
- logging.basicConfig(level=logging.INFO, format='[' + METADATA["name"] + '] %(levelname)s %(asctime)s %(name)s: %(message)s',)
+ logging.basicConfig(level=logging.INFO, format='[' + METADATA["shortName"] + '] %(levelname)s %(asctime)s %(name)s: %(message)s',)
#logging.getLogger().setLevel(logging.INFO) #development
else: #production
- logging.basicConfig(level=logging.ERROR, format='[' + METADATA["name"] + '] %(levelname)s %(asctime)s %(name)s: %(message)s',)
+ logging.basicConfig(level=logging.ERROR, format='[' + METADATA["shortName"] + '] %(levelname)s %(asctime)s %(name)s: %(message)s',)
#logging.getLogger().setLevel(logging.ERROR) #production
diff --git a/qtgui/designer/mainwindow.py b/qtgui/designer/mainwindow.py
index 871cc83..6f2d9ac 100644
--- a/qtgui/designer/mainwindow.py
+++ b/qtgui/designer/mainwindow.py
@@ -275,9 +275,13 @@ class Ui_MainWindow(object):
self.actionManual.setObjectName("actionManual")
self.actionChangelog = QtWidgets.QAction(MainWindow)
self.actionChangelog.setObjectName("actionChangelog")
+ self.actionSplit_Session_View_The_Other_Way = QtWidgets.QAction(MainWindow)
+ self.actionSplit_Session_View_The_Other_Way.setCheckable(True)
+ self.actionSplit_Session_View_The_Other_Way.setObjectName("actionSplit_Session_View_The_Other_Way")
self.menuControl.addAction(self.actionManual)
self.menuControl.addAction(self.actionChangelog)
self.menuControl.addAction(self.actionRebuild_Program_Database)
+ self.menuControl.addAction(self.actionSplit_Session_View_The_Other_Way)
self.menuControl.addAction(self.actionHide_in_System_Tray)
self.menuControl.addAction(self.actionSettings)
self.menuControl.addAction(self.actionMenuQuit)
@@ -378,3 +382,4 @@ class Ui_MainWindow(object):
self.actionSettings.setText(_translate("MainWindow", "Settings"))
self.actionManual.setText(_translate("MainWindow", "Manual"))
self.actionChangelog.setText(_translate("MainWindow", "News and Changelog"))
+ self.actionSplit_Session_View_The_Other_Way.setText(_translate("MainWindow", "Split Session View the other way"))
diff --git a/qtgui/designer/mainwindow.ui b/qtgui/designer/mainwindow.ui
index b2fbe33..fed2dd6 100644
--- a/qtgui/designer/mainwindow.ui
+++ b/qtgui/designer/mainwindow.ui
@@ -566,6 +566,7 @@
+
@@ -738,6 +739,14 @@
News and Changelog
+
+
+ true
+
+
+ Split Session View the other way
+
+
diff --git a/qtgui/mainwindow.py b/qtgui/mainwindow.py
index efa88ba..39c6012 100644
--- a/qtgui/mainwindow.py
+++ b/qtgui/mainwindow.py
@@ -327,6 +327,18 @@ class MainWindow(QtWidgets.QMainWindow):
self.setVisible(False)
#self.systemTray.buildContextMenu() #Don't. This crashes Qt through some delayed execution of who knows what. Workaround: tray context menu now say "Show/Hide" and not only the actual state.
+
+ def toggleSplitSessionView(self, state:bool):
+ self.ui.actionSplit_Session_View_The_Other_Way.blockSignals(True)
+ if state:
+ orientation = QtCore.Qt.Vertical #this is weird. Is the Qt enum wrongly labeled? This splits in an upper and lower part.
+ else:
+ orientation = QtCore.Qt.Horizontal
+ self.ui.actionSplit_Session_View_The_Other_Way.setChecked(state) #This funtion can be called by functions, e.g. restoreWindowSettings on startup.
+ self.ui.hSplitterLauncherClients.setOrientation(orientation)
+ self.ui.actionSplit_Session_View_The_Other_Way.blockSignals(False)
+
+
def _askBeforeQuit(self, nsmSessionName):
"""If you quit while in a session ask what to do.
The TrayIcon context menu uses different functions and directly acts, without a question"""
@@ -404,6 +416,7 @@ class MainWindow(QtWidgets.QMainWindow):
self.ui.actionChangelog.triggered.connect(self.changelog.show)
self.ui.actionRebuild_Program_Database.triggered.connect(self.updateProgramDatabase)
self.ui.actionSettings.triggered.connect(self._reactMenu_settings)
+ self.ui.actionSplit_Session_View_The_Other_Way.toggled.connect(self.toggleSplitSessionView)
self.ui.actionHide_in_System_Tray.triggered.connect(lambda: self.toggleVisible(force=False))
self.ui.actionMenuQuit.triggered.connect(self.menuRealQuit)
@@ -431,6 +444,7 @@ class MainWindow(QtWidgets.QMainWindow):
#settings.setValue("visible", self.isVisible()) Deprecated. see restoreWindowSettings
settings.setValue("recentlyOpenedSessions", self.recentlyOpenedSessions.get())
settings.setValue("tab", self.ui.tabbyCat.currentIndex())
+ settings.setValue("sessionSplitOrientationNonDefault", self.ui.actionSplit_Session_View_The_Other_Way.isChecked())
def restoreWindowSettings(self):
"""opposite of storeWindowSettings. Read there."""
@@ -442,11 +456,13 @@ class MainWindow(QtWidgets.QMainWindow):
"windowState":self.restoreState,
"recentlyOpenedSessions":self.recentlyOpenedSessions.load,
"tab": lambda i: self.ui.tabbyCat.setCurrentIndex(int(i)),
+ "sessionSplitOrientationNonDefault": lambda b: self.toggleSplitSessionView(bool(b)),
}
types = {
"recentlyOpenedSessions": list,
"tab": int,
+ "sessionSplitOrientationNonDefault": bool,
}
for key in settings.allKeys():