mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-09 07:36:48 +02:00
* Disable anti-aliasing / enable text anti-aliasing in several places.
This commit is contained in:
@@ -219,7 +219,7 @@ ColumnItemDelegate::paint( QPainter* painter, const QStyleOptionViewItem& option
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
painter->save();
|
painter->save();
|
||||||
painter->setRenderHint( QPainter::Antialiasing );
|
painter->setRenderHint( QPainter::TextAntialiasing );
|
||||||
painter->setPen( opt.palette.color( QPalette::Text ) );
|
painter->setPen( opt.palette.color( QPalette::Text ) );
|
||||||
|
|
||||||
QRect r = option.rect.adjusted( 8, 2, -option.rect.width() + option.rect.height() + 4, -2 );
|
QRect r = option.rect.adjusted( 8, 2, -option.rect.width() + option.rect.height() + 4, -2 );
|
||||||
|
@@ -117,7 +117,7 @@ GridItemDelegate::paint( QPainter* painter, const QStyleOptionViewItem& option,
|
|||||||
}
|
}
|
||||||
|
|
||||||
painter->save();
|
painter->save();
|
||||||
// painter->setRenderHint( QPainter::Antialiasing );
|
painter->setRenderHint( QPainter::TextAntialiasing );
|
||||||
|
|
||||||
if ( !m_covers.contains( index ) )
|
if ( !m_covers.contains( index ) )
|
||||||
{
|
{
|
||||||
|
@@ -93,6 +93,7 @@ void
|
|||||||
ClickableLabel::paintEvent( QPaintEvent* event )
|
ClickableLabel::paintEvent( QPaintEvent* event )
|
||||||
{
|
{
|
||||||
QPainter painter( this );
|
QPainter painter( this );
|
||||||
|
painter.setRenderHint( QPainter::TextAntialiasing );
|
||||||
painter.setOpacity( m_opacity );
|
painter.setOpacity( m_opacity );
|
||||||
|
|
||||||
const QString elidedText = fontMetrics().elidedText( text(), Qt::ElideRight, contentsRect().width() );
|
const QString elidedText = fontMetrics().elidedText( text(), Qt::ElideRight, contentsRect().width() );
|
||||||
|
@@ -176,6 +176,8 @@ ElidedLabel::paintEvent( QPaintEvent* event )
|
|||||||
{
|
{
|
||||||
QFrame::paintEvent( event );
|
QFrame::paintEvent( event );
|
||||||
QPainter p( this );
|
QPainter p( this );
|
||||||
|
p.setRenderHint( QPainter::TextAntialiasing );
|
||||||
|
|
||||||
QRect r = contentsRect();
|
QRect r = contentsRect();
|
||||||
r.adjust( m_margin, m_margin, -m_margin, -m_margin );
|
r.adjust( m_margin, m_margin, -m_margin, -m_margin );
|
||||||
|
|
||||||
|
@@ -286,6 +286,7 @@ void
|
|||||||
QueryLabel::paintEvent( QPaintEvent* /* event */ )
|
QueryLabel::paintEvent( QPaintEvent* /* event */ )
|
||||||
{
|
{
|
||||||
QPainter p( this );
|
QPainter p( this );
|
||||||
|
p.setRenderHint( QPainter::TextAntialiasing );
|
||||||
QRect r = contentsRect();
|
QRect r = contentsRect();
|
||||||
|
|
||||||
if ( m_hovering )
|
if ( m_hovering )
|
||||||
|
Reference in New Issue
Block a user