1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-08-01 03:40:16 +02:00

Center text

This commit is contained in:
Hannah von Reth
2015-11-21 01:15:04 +01:00
parent 365a021a29
commit cf7194407b

View File

@@ -603,7 +603,7 @@ TomahawkWindow::updatePreview()
doc.setDefaultFont( font ); doc.setDefaultFont( font );
doc.setPageSize( QSize( size.width() - 2 * margin - coverSize.width() , size.height() - 2 * margin ) ); doc.setPageSize( QSize( size.width() - 2 * margin - coverSize.width() , size.height() - 2 * margin ) );
doc.setHtml( QString( "<font color=\"white\">%1</font>" ).arg( title )); doc.setHtml( QString( "<center><font color=\"white\">%1</font></center>" ).arg( title ));
paint.save(); paint.save();
paint.translate( coverSize.width() + 2 * margin , ( size.height() - doc.size().height() ) / 2); paint.translate( coverSize.width() + 2 * margin , ( size.height() - doc.size().height() ) / 2);