profile: scale dive event items according to font print scale

When printing with low DPI, the dive event items become comically
large, because they are not resized like the fonts. Therefore,
scale using the fontPrintScale.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2021-07-04 17:27:10 +02:00 committed by Dirk Hohndel
parent 6b2e56e513
commit 65580fceda
3 changed files with 7 additions and 6 deletions

View file

@ -721,7 +721,7 @@ void ProfileWidget2::plotDive(const struct dive *dIn, int dcIn, bool doClearPict
// printMode is always selected for SUBSURFACE_MOBILE due to font problems
// BUT events are wanted.
#endif
DiveEventItem *item = new DiveEventItem(d, event, lastgasmix, dataModel, timeAxis, profileYAxis, animSpeed);
DiveEventItem *item = new DiveEventItem(d, event, lastgasmix, dataModel, timeAxis, profileYAxis, animSpeed, getFontPrintScale());
item->setZValue(2);
#ifndef SUBSURFACE_MOBILE
item->setScale(printMode ? 4 :1);