profilegraphics.cpp: Use text sizes in plot_text()

Make the active font (fnt) use the 'size' member of the received
text_render_options_t. This allows changing the size of
certain text elements.

For the moment most text elements are set to 12px.

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Lubomir I. Ivanov 2013-10-15 12:54:18 +03:00 committed by Dirk Hohndel
parent 88b1e09dee
commit 005f8ecf83

View file

@ -1179,7 +1179,7 @@ QGraphicsItemGroup *ProfileGraphicsView::plot_text(text_render_options_t *tro,co
QFontMetrics fm(fnt);
if (printMode)
fnt.setPixelSize(10);
fnt.setPixelSize(tro->size);
QPointF point(SCALEGC(pos.x(), pos.y())); // This is neded because of the SCALE macro.
double dx = tro->hpos * (fm.width(text));