mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-04 05:07:27 +02:00
* Properly calculate JobStatusItem's row height, taking current font settings into account.
This commit is contained in:
@@ -19,13 +19,14 @@
|
||||
#include "JobStatusDelegate.h"
|
||||
|
||||
#include "JobStatusModel.h"
|
||||
#include "utils/TomahawkUtilsGui.h"
|
||||
#include "utils/Logger.h"
|
||||
|
||||
#include <QPainter>
|
||||
#include <QApplication>
|
||||
#include <QListView>
|
||||
|
||||
#define ROW_HEIGHT 20
|
||||
#define ROW_HEIGHT ( TomahawkUtils::defaultFontHeight() + 6 )
|
||||
#define ICON_PADDING 2
|
||||
#define PADDING 2
|
||||
|
||||
@@ -80,7 +81,7 @@ JobStatusDelegate::paint( QPainter* painter, const QStyleOptionViewItem& option,
|
||||
rightEdge = rRect.left();
|
||||
}
|
||||
|
||||
const int mainW = rightEdge - 4 * PADDING - iconRect.right();
|
||||
const int mainW = rightEdge - 6 * PADDING - iconRect.right();
|
||||
QString mainText = index.data( Qt::DisplayRole ).toString();
|
||||
QTextOption to( Qt::AlignLeft | Qt::AlignVCenter );
|
||||
if ( !allowMultiLine )
|
||||
|
Reference in New Issue
Block a user