mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-05-06 00:03:46 +02:00
Fix #1404234 [Icon not showing on Comments custom column](https://bugs.launchpad.net/calibre/+bug/1404234)
This commit is contained in:
parent
c7b18b6373
commit
9339ed74f1
1 changed files with 5 additions and 0 deletions
|
|
@ -416,6 +416,11 @@ def paint(self, painter, option, index):
|
|||
else option.widget.style()
|
||||
self.document.setHtml(option.text)
|
||||
style.drawPrimitive(QStyle.PE_PanelItemViewItem, option, painter, widget=option.widget)
|
||||
rect = style.subElementRect(QStyle.SE_ItemViewItemDecoration, option)
|
||||
ic = option.icon
|
||||
if rect.isValid() and not ic.isNull():
|
||||
sz = ic.actualSize(option.decorationSize)
|
||||
painter.drawPixmap(rect.topLeft(), ic.pixmap(sz))
|
||||
ctx = QAbstractTextDocumentLayout.PaintContext()
|
||||
ctx.palette = option.palette
|
||||
if option.state & QStyle.State_Selected:
|
||||
|
|
|
|||
Loading…
Reference in a new issue