From b32bc409c18ceb4cd8147f11021e2c4b2746184b Mon Sep 17 00:00:00 2001 From: bd Date: Sat, 26 Apr 2025 14:41:02 -0400 Subject: right-align colum headers on table objects --- gui/storageview.cc | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'gui/storageview.cc') diff --git a/gui/storageview.cc b/gui/storageview.cc index f6f9736..43837a9 100644 --- a/gui/storageview.cc +++ b/gui/storageview.cc @@ -48,6 +48,13 @@ QVariant StorageView::data(const QModelIndex &i, int role) const QVariant StorageView::headerData(int section, Qt::Orientation o, int role) const { + Qt::Alignment a; + + if (role == Qt::TextAlignmentRole) { + a = Qt::AlignRight | Qt::AlignVCenter; + return QVariant(static_cast(a)); + } + if (role != Qt::DisplayRole) return QVariant(); -- cgit v1.2.3