From 1005fce494ebf5a3aa2a801341783e36f8d92a0f Mon Sep 17 00:00:00 2001 From: Charles Haley <> Date: Thu, 24 Jan 2013 13:53:13 +0100 Subject: [PATCH] Make custom columns using bool icons put text values under the icons. --- src/calibre/gui2/library/models.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/calibre/gui2/library/models.py b/src/calibre/gui2/library/models.py index bbd8566a37..d0200408bd 100644 --- a/src/calibre/gui2/library/models.py +++ b/src/calibre/gui2/library/models.py @@ -634,13 +634,12 @@ class BooksModel(QAbstractTableModel): # {{{ def bool_type_decorator(r, idx=-1, bool_cols_are_tristate=True): val = force_to_bool(self.db.data[r][idx]) - if not bool_cols_are_tristate: - if val is None or not val: + if val is None: + if not bool_cols_are_tristate: return self.bool_no_icon + return None if val: return self.bool_yes_icon - if val is None: - return self.bool_blank_icon return self.bool_no_icon def ondevice_decorator(r, idx=-1):