diff --git a/src/qt/overviewpage.cpp b/src/qt/overviewpage.cpp index b7f1915c9c1..57510b4fdf3 100644 --- a/src/qt/overviewpage.cpp +++ b/src/qt/overviewpage.cpp @@ -69,18 +69,18 @@ public: foreground = brush.color(); } + if (index.data(TransactionTableModel::WatchonlyRole).toBool()) { + QIcon iconWatchonly = qvariant_cast(index.data(TransactionTableModel::WatchonlyDecorationRole)); + QRect watchonlyRect(addressRect.left(), addressRect.top(), 16, addressRect.height()); + iconWatchonly = platformStyle->TextColorIcon(iconWatchonly); + iconWatchonly.paint(painter, watchonlyRect); + addressRect.setLeft(addressRect.left() + watchonlyRect.width() + 5); + } + painter->setPen(foreground); QRect boundingRect; painter->drawText(addressRect, Qt::AlignLeft | Qt::AlignVCenter, address, &boundingRect); - if (index.data(TransactionTableModel::WatchonlyRole).toBool()) - { - QIcon iconWatchonly = qvariant_cast(index.data(TransactionTableModel::WatchonlyDecorationRole)); - QRect watchonlyRect(boundingRect.right() + 5, mainRect.top()+ypad+halfheight, 16, halfheight); - iconWatchonly = platformStyle->TextColorIcon(iconWatchonly); - iconWatchonly.paint(painter, watchonlyRect); - } - if(amount < 0) { foreground = COLOR_NEGATIVE;