mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-04-30 03:54:58 +02:00
Improve robustness in column coloring.
This commit is contained in:
parent
29b453ba23
commit
de969af505
1 changed files with 2 additions and 1 deletions
|
|
@ -715,7 +715,8 @@ def data(self, index, role):
|
|||
fmt = self.column_color_map[key]
|
||||
try:
|
||||
color = composite_formatter.safe_format(fmt, mi, '', mi)
|
||||
return QColor(color)
|
||||
if QColor.isValid(color):
|
||||
return QColor(color)
|
||||
except:
|
||||
return None
|
||||
elif self.is_custom_column(key) and \
|
||||
|
|
|
|||
Loading…
Reference in a new issue