diff --git a/src/gui_qt/graphs/graphwindow.py b/src/gui_qt/graphs/graphwindow.py index 7796b81..e3e19a8 100644 --- a/src/gui_qt/graphs/graphwindow.py +++ b/src/gui_qt/graphs/graphwindow.py @@ -75,6 +75,8 @@ class QGraphWindow(QtWidgets.QGraphicsView, Ui_GraphWindow): self.scene.contextMenu[0].disconnect() self.scene.contextMenu[0].triggered.connect(self.export_dialog) + self.bwbutton.toggled.connect(self.change_background) + def _init_gui(self): self.setWindowTitle('Graph ' + str(next(QGraphWindow.counter))) @@ -772,7 +774,6 @@ class QGraphWindow(QtWidgets.QGraphicsView, Ui_GraphWindow): if y is not None: self.plotItem.setLabel('left', y, **{'font-size': '10pt', 'color': self._fgcolor.name()}) - @QtCore.pyqtSlot(bool, name='on_bwbutton_toggled') def change_background(self, _): temp = self._fgcolor, self._bgcolor self.set_color(foreground=self._prev_colors[0], background=self._prev_colors[1])