mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-11 08:34:34 +02:00
* Fixed hovering of elided QueryLabels.
This commit is contained in:
@@ -292,8 +292,14 @@ QueryLabel::paintEvent( QPaintEvent* event )
|
|||||||
p.save();
|
p.save();
|
||||||
p.setRenderHint( QPainter::Antialiasing );
|
p.setRenderHint( QPainter::Antialiasing );
|
||||||
|
|
||||||
if ( elidedText == s && m_hoverArea.width() )
|
if ( m_hoverArea.width() )
|
||||||
{
|
{
|
||||||
|
if ( elidedText != s )
|
||||||
|
{
|
||||||
|
m_hoverArea.setLeft( 0 );
|
||||||
|
m_hoverArea.setRight( fontMetrics().width( elidedText ) + contentsMargins().left() * 2 );
|
||||||
|
}
|
||||||
|
|
||||||
p.setPen( palette().mid().color() );
|
p.setPen( palette().mid().color() );
|
||||||
p.setBrush( palette().highlight() );
|
p.setBrush( palette().highlight() );
|
||||||
p.drawRoundedRect( m_hoverArea, 4.0, 4.0 );
|
p.drawRoundedRect( m_hoverArea, 4.0, 4.0 );
|
||||||
|
Reference in New Issue
Block a user