Skip to content

Commit

Permalink
Overview Fix Card Font size on MacOS
Browse files Browse the repository at this point in the history
.. the font selections was incorrect on MacOS and
   caused the PMC card to be rendered incorrectly.
  • Loading branch information
liversedge committed Feb 21, 2017
1 parent 1bd5780 commit b457d40
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions src/Charts/OverviewWindow.cpp
Expand Up @@ -800,20 +800,18 @@ Card::paint(QPainter *painter, const QStyleOptionGraphicsItem *, QWidget *) {

// fonts
QFont titlefont;
titlefont.setPointSize(ROWHEIGHT-18); // need a bit of space
QFont bigfont;
QFont smallfont;
#ifdef Q_OS_MAC
titlefont.setPointSize(ROWHEIGHT); // need a bit of space
bigfont.setPointSize(double(ROWHEIGHT)*2.5f);
smallfont.setPointSize(ROWHEIGHT*0.8f);
#else
titlefont.setPointSize(ROWHEIGHT-18); // need a bit of space
bigfont.setPointSize(ROWHEIGHT*2);
smallfont.setPointSize(ROWHEIGHT);
#endif

QFont smallfont;
#ifdef Q_OS_MAC
smallfont.setPointSize(ROWHEIGHT);
#else
smallfont.setPointSize(ROWHEIGHT*0.6f);
#endif

painter->setBrush(brush);
QPainterPath path;
Expand Down

0 comments on commit b457d40

Please sign in to comment.