remove unused internal QPaintEngine::coordinateOffset() method

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
Ivailo Monev 2021-12-07 23:09:13 +02:00
parent ce798af227
commit 13b6b3a1c8
3 changed files with 0 additions and 20 deletions

View file

@ -780,20 +780,6 @@ QPaintDevice *QPaintEngine::paintDevice() const
return d_func()->pdev; return d_func()->pdev;
} }
/*!
\internal
Returns the offset from the painters origo to the engines
origo. This value is used by QPainter for engines who have
internal double buffering.
This function only makes sense when the engine is active.
*/
QPoint QPaintEngine::coordinateOffset() const
{
return QPoint();
}
/*! /*!
\internal \internal

View file

@ -150,8 +150,6 @@ public:
void setSystemRect(const QRect &rect); void setSystemRect(const QRect &rect);
QRect systemRect() const; QRect systemRect() const;
virtual QPoint coordinateOffset() const;
enum Type { enum Type {
X11, X11,
PostScript, PostScript,

View file

@ -190,7 +190,6 @@ bool QPainterPrivate::attachPainterPrivate(QPainter *q, QPaintDevice *pdev)
q->initFrom(widget); q->initFrom(widget);
QPoint offset; QPoint offset;
widget->d_func()->redirected(&offset); widget->d_func()->redirected(&offset);
offset += q->d_ptr->engine->coordinateOffset();
// Update system rect. // Update system rect.
q->d_ptr->state->ww = q->d_ptr->state->vw = widget->width(); q->d_ptr->state->ww = q->d_ptr->state->vw = widget->width();
@ -1539,9 +1538,6 @@ bool QPainter::begin(QPaintDevice *pd)
d->state->wh = d->state->vh = pd->metric(QPaintDevice::PdmHeight); d->state->wh = d->state->vh = pd->metric(QPaintDevice::PdmHeight);
} }
const QPoint coordinateOffset = d->engine->coordinateOffset();
d->state->redirectionMatrix.translate(-coordinateOffset.x(), -coordinateOffset.y());
Q_ASSERT(d->engine->isActive()); Q_ASSERT(d->engine->isActive());
if (!d->state->redirectionMatrix.isIdentity()) if (!d->state->redirectionMatrix.isIdentity())