cleanup: prevent distracing conversion warnings

We do want the -Wfloat-conversion warnings where they point out
potential bugs. But they are very distracting when they are triggered by
floating point literals (which the standard defines as double) passed to
a function expecting float arguments.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2022-02-15 11:23:27 -08:00
parent 4b539ef044
commit 008f8ad21e
6 changed files with 68 additions and 65 deletions

View file

@ -87,7 +87,7 @@ void RegressionItem::updatePosition()
img->fill(Qt::transparent);
if (confidence) {
QColor col(regressionItemColor);
col.setAlphaF(reg.r2);
col.setAlphaF((float)reg.r2);
painter->setPen(Qt::NoPen);
painter->setBrush(QBrush(col));
painter->drawPolygon(poly);