Mercurial > hg > easyhg
diff src/changesetview.cpp @ 683:759b81c38bb1
Make hinting more consistent
author | Chris Cannam |
---|---|
date | Fri, 07 Dec 2018 17:13:47 +0000 |
parents | ad3e5693cb76 |
children | 744933aba33a |
line wrap: on
line diff
--- a/src/changesetview.cpp Fri Dec 07 14:29:23 2018 +0000 +++ b/src/changesetview.cpp Fri Dec 07 17:13:47 2018 +0000 @@ -61,6 +61,13 @@ QFont f(paint->font()); f.setPixelSize(11); f.setBold(true); + QTransform t = paint->worldTransform(); + float scale = std::min(t.m11(), t.m22()); + if (scale > 1.0) { +#ifdef Q_OS_WIN32 + f.setHintingPreference(QFont::PreferVerticalHinting); +#endif + } paint->setFont(f); float x = mapToScene(0, 0).x();