From d19b7a777f3002aa404beb91b05d92b45706807b Mon Sep 17 00:00:00 2001 From: Gabriele Date: Mon, 1 Dec 2014 22:49:32 +0100 Subject: [PATCH] Vertical align right-aligned header text Since e907306b411 ("Right align header text that also has right-aligned row text"), right-aligned elements are no longer centered vertically. This can be noticed with some Qt styles (e.g. Breeze). --- src/qtlibtorrent/torrentmodel.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/qtlibtorrent/torrentmodel.cpp b/src/qtlibtorrent/torrentmodel.cpp index 85623bead..0cf190544 100644 --- a/src/qtlibtorrent/torrentmodel.cpp +++ b/src/qtlibtorrent/torrentmodel.cpp @@ -402,7 +402,7 @@ QVariant TorrentModel::headerData(int section, Qt::Orientation orientation, case TorrentModelItem::TR_RATIO: case TorrentModelItem::TR_PRIORITY: case TorrentModelItem::TR_LAST_ACTIVITY: - return Qt::AlignRight; + return QVariant(Qt::AlignRight | Qt::AlignVCenter); default: return QAbstractListModel::headerData(section, orientation, role); }