mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Show authors in addition to title when cover not available
This commit is contained in:
parent
0e64b0c886
commit
10b4b9d39c
@ -398,7 +398,8 @@ class CoverDelegate(QStyledItemDelegate):
|
|||||||
rect.adjust(4, 4, -4, -4)
|
rect.adjust(4, 4, -4, -4)
|
||||||
if cdata is None or cdata is False:
|
if cdata is None or cdata is False:
|
||||||
title = db.field_for('title', book_id, default_value='')
|
title = db.field_for('title', book_id, default_value='')
|
||||||
painter.drawText(rect, Qt.AlignCenter|Qt.TextWordWrap, title)
|
authors = ' & '.join(db.field_for('authors', book_id, default_value=()))
|
||||||
|
painter.drawText(rect, Qt.AlignCenter|Qt.TextWordWrap, '%s\n\n%s' % (title, authors))
|
||||||
if cdata is False:
|
if cdata is False:
|
||||||
self.render_queue.put(book_id)
|
self.render_queue.put(book_id)
|
||||||
else:
|
else:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user