From 4b002c06ba831b9c60fe9b86e14a2dd27da0891f Mon Sep 17 00:00:00 2001 From: Nathan Jessurun Date: Sat, 3 Apr 2021 17:07:02 -0400 Subject: [PATCH] revert to old behavior: default created from value if not present --- pyqtgraph/parametertree/Parameter.py | 1 + 1 file changed, 1 insertion(+) diff --git a/pyqtgraph/parametertree/Parameter.py b/pyqtgraph/parametertree/Parameter.py index 2d830273..c084634a 100644 --- a/pyqtgraph/parametertree/Parameter.py +++ b/pyqtgraph/parametertree/Parameter.py @@ -201,6 +201,7 @@ class Parameter(QtCore.QObject): if 'default' not in self.opts: self.opts['default'] = None + self.setDefault(self.opts['value']) ## Connect all state changed signals to the general sigStateChanged self.sigValueChanged.connect(self._emitValueChanged)