Commit ef521dac authored by Dmitry Kazakov's avatar Dmitry Kazakov
Browse files

Disable partial updates for fractional HiDPI cases

There is some bug either in QPainter or in our partial updates
patches that cause an update issue in reference images decoration.

Basically, the crop rect of the update should be aligned to the
physical pixels, but it is not.

CCBUG:441216
parent 0da6f32e
Pipeline #269451 passed with stage
in 51 minutes and 48 seconds
......@@ -232,7 +232,17 @@ void KisOpenGLCanvas2::paintEvent(QPaintEvent *e)
{
KIS_SAFE_ASSERT_RECOVER_RETURN(!d->updateRect);
d->updateRect = e->rect();
if (qFuzzyCompare(devicePixelRatioF(), qRound(devicePixelRatioF()))) {
/**
* Enable partial updates **only** for the case when we have
* integer scaling. There is a bug in Qt that causes artifacts
* otherwise:
*
* See https://bugs.kde.org/show_bug.cgi?id=441216
*/
d->updateRect = e->rect();
}
QOpenGLWidget::paintEvent(e);
d->updateRect = boost::none;
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment