8#include <qpa/qplatformwindow.h>
9#include <QtGui/qscreen.h>
10#include <QtGui/qpainter.h>
14QFbBackingStore::QFbBackingStore(QWindow *window)
15 : QPlatformBackingStore(window)
18 (
static_cast<QFbWindow *>(window->handle()))->setBackingStore(
this);
20 (
static_cast<QFbScreen *>(window->screen()->handle()))->addPendingBackingStore(
this);
32 (
static_cast<
QFbWindow *>(window->handle()))->repaint(region);
37 Q_UNUSED(staticContents);
39 if (mImage.size() != size)
40 mImage = QImage(size, window()->screen()->handle()->format());
68 if (mImage.hasAlphaChannel()) {
70 p.setCompositionMode(QPainter::CompositionMode_Source);
71 for (
const QRect &r : region)
72 p.fillRect(r, Qt::transparent);
void resize(const QSize &size, const QRegion ®ion) override
void flush(QWindow *window, const QRegion ®ion, const QPoint &offset) override
Flushes the given region from the specified window.
QImage toImage() const override
Implemented in subclasses to return the content of the backingstore as a QImage.
void endPaint() override
This function is called after painting onto the surface has ended.
void beginPaint(const QRegion &) override
This function is called before painting onto the surface begins, with the region in which the paintin...