We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4eb42fd commit 5acf882Copy full SHA for 5acf882
iblqt/core.py
@@ -360,10 +360,10 @@ def data(
360
row = self._dataFrame.index[index.row()]
361
col = index.column()
362
if role == Qt.BackgroundRole:
363
- rgb = self._background[row][col]
364
- return QVariant(QColor.fromRgb(*rgb, self._alpha))
+ r, g, b = self._background[row][col]
+ return QVariant(QColor.fromRgb(r, g, b, self._alpha))
365
if role == Qt.ForegroundRole:
366
- lum: int = self._foreground[row][col]
+ lum = self._foreground[row][col]
367
color = QColor('black' if (lum * self._alpha) < 32512 else 'white')
368
return QVariant(color)
369
return super().data(index, role)
0 commit comments