mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-07-31 11:20:22 +02:00
Scale up artist bio font size with DpiScaler to make it always readable
This commit is contained in:
@@ -53,11 +53,11 @@ public:
|
||||
static QMargins scaled( const QPaintDevice* pd, const QMargins& margins );
|
||||
static int scaledX( const QPaintDevice* pd, int x );
|
||||
static int scaledY( const QPaintDevice* pd, int y );
|
||||
inline static qreal ratioFromFontHeight();
|
||||
|
||||
private:
|
||||
inline static qreal ratioX( const QPaintDevice* pd );
|
||||
inline static qreal ratioY( const QPaintDevice* pd );
|
||||
inline static qreal ratioFromFontHeight();
|
||||
|
||||
qreal m_ratioX;
|
||||
qreal m_ratioY;
|
||||
|
@@ -124,6 +124,7 @@ ArtistInfoWidget::ArtistInfoWidget( const Tomahawk::artist_ptr& artist, QWidget*
|
||||
ui->biography->page()->mainFrame()->setScrollBarPolicy( Qt::Horizontal, Qt::ScrollBarAlwaysOff );
|
||||
ui->biography->page()->mainFrame()->setScrollBarPolicy( Qt::Vertical, Qt::ScrollBarAsNeeded );
|
||||
ui->biography->page()->setLinkDelegationPolicy( QWebPage::DelegateAllLinks );
|
||||
ui->biography->setTextSizeMultiplier( DpiScaler::ratioFromFontHeight() );
|
||||
ui->biography->installEventFilter( this );
|
||||
|
||||
TomahawkStyle::stylePageWidget( ui->biography );
|
||||
|
Reference in New Issue
Block a user