From 735896e68d3618d5cf53750e63cfda276da1bae1 Mon Sep 17 00:00:00 2001 From: Dominik Demuth Date: Mon, 13 Nov 2023 17:11:38 +0100 Subject: [PATCH] background color of legend is not changed; fixes #141 --- src/gui_qt/graphs/graphwindow.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gui_qt/graphs/graphwindow.py b/src/gui_qt/graphs/graphwindow.py index 3cfc6f0..c4d7152 100644 --- a/src/gui_qt/graphs/graphwindow.py +++ b/src/gui_qt/graphs/graphwindow.py @@ -753,7 +753,7 @@ class QGraphWindow(QtWidgets.QGraphicsView, Ui_GraphWindow): if background is not None: self._bgcolor = mkColor(background) self.graphic.setBackground(self._bgcolor) - self.legend.setBrush(self._bgcolor) + # self.legend.setBrush(self._bgcolor) if foreground is not None: self._fgcolor = mkColor(foreground) @@ -770,7 +770,7 @@ class QGraphWindow(QtWidgets.QGraphicsView, Ui_GraphWindow): self.show_legend() title = self.plotItem.titleLabel.text - if title is not None: + if title is not None and title != '': self.plotItem.setTitle(title, **{'size': '10pt', 'color': self._fgcolor}) x = self.plotItem.getAxis('bottom').labelText