From b1705ae246b3a2b3f4bb69a0ca121d2b4cdfba7f Mon Sep 17 00:00:00 2001 From: Christian Muehlhaeuser Date: Tue, 4 Nov 2014 17:19:07 +0100 Subject: [PATCH] Set default font size for generic sidebar items. --- src/tomahawk/sourcetree/SourceDelegate.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/tomahawk/sourcetree/SourceDelegate.cpp b/src/tomahawk/sourcetree/SourceDelegate.cpp index 00a1e7fdb..12fc7a219 100644 --- a/src/tomahawk/sourcetree/SourceDelegate.cpp +++ b/src/tomahawk/sourcetree/SourceDelegate.cpp @@ -98,6 +98,10 @@ SourceDelegate::sizeHint( const QStyleOptionViewItem& option, const QModelIndex& void SourceDelegate::paintStandardItem( QPainter* painter, const QStyleOptionViewItem& option, const QModelIndex& index, const QString& count ) const { + QFont font = painter->font(); + font.setPointSize( TomahawkUtils::defaultFontSize() ); + painter->setFont( font ); + SourcesModel::RowType type = static_cast< SourcesModel::RowType >( index.data( SourcesModel::SourceTreeItemTypeRole ).toInt() ); const bool upperCase = !( type == SourcesModel::StaticPlaylist || type == SourcesModel::AutomaticPlaylist ||