File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
lib/matplotlib/backends/qt_editor Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -243,8 +243,14 @@ def setup(self):
243
243
elif isinstance (value , str ):
244
244
field = QtWidgets .QLineEdit (value , self )
245
245
elif isinstance (value , (list , tuple )):
246
+ if isinstance (value , tuple ):
247
+ value = list (value )
248
+ # Note: get() below checks the type of value[0] in self.data so
249
+ # it is essential that value gets modified in-place.
250
+ # This means that the code is actually broken in the case where
251
+ # value is a tuple, but fortunately we always pass a list...
252
+ selindex = value .pop (0 )
246
253
field = QtWidgets .QComboBox (self )
247
- selindex , * value = value
248
254
if isinstance (value [0 ], (list , tuple )):
249
255
keys = [key for key , _val in value ]
250
256
value = [val for _key , val in value ]
You can’t perform that action at this time.
0 commit comments