Debian Codegraph @

xcb/libqt5xcbqpa-dev/5.7.1/qxcbbackingstore.h

raw
1 // Copyright (C) 2016 The Qt Company Ltd.
2 //
3 // SPDX-License-Identifier: LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
4
5 #ifndef QXCBBACKINGSTORE_H
6 #define QXCBBACKINGSTORE_H
7
8 #include <qpa/qplatformbackingstore.h>
9 #include <QtCore/QStack>
10
11 #include <xcb/xcb.h>
12
13 #include "qxcbobject.h"
14
15 QT_BEGIN_NAMESPACE
16
17 class QXcbShmImage;
18
19 class QXcbBackingStore : public QXcbObject, public QPlatformBackingStore
20 {
21 public:
22 QXcbBackingStore(QWindow *widget);
23 ~QXcbBackingStore();
24
25 QPaintDevice *paintDevice() Q_DECL_OVERRIDE;
26 void flush(QWindow *window, const QRegion &region, const QPoint &offset) Q_DECL_OVERRIDE;
27 #ifndef QT_NO_OPENGL
28 void composeAndFlush(QWindow *window, const QRegion &region, const QPoint &offset,
29 QPlatformTextureList *textures, QOpenGLContext *context,
30 bool translucentBackground) Q_DECL_OVERRIDE;
31 QImage toImage() const Q_DECL_OVERRIDE;
32 #endif
33
34 QPlatformGraphicsBuffer *graphicsBuffer() const Q_DECL_OVERRIDE;
35
36 void resize(const QSize &size, const QRegion &staticContents) Q_DECL_OVERRIDE;
37 bool scroll(const QRegion &area, int dx, int dy) Q_DECL_OVERRIDE;
38
39 void beginPaint(const QRegion &) Q_DECL_OVERRIDE;
40 void endPaint() Q_DECL_OVERRIDE;
41
42 private:
43 QXcbShmImage *m_image;
44 QStack<QRegion> m_paintRegions;
45 QImage m_rgbImage;
46 };
47
48 QT_END_NAMESPACE
49
50 #endif