aboutsummaryrefslogtreecommitdiffstats
path: root/sources/pyside6/PySide6/qpytextobject.h
blob: 45bb0bd5281bd9665a5dd5b3663406e48dd90afc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
// Copyright (C) 2021 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only

#ifndef QPYTEXTOBJECT
#define QPYTEXTOBJECT

#include <QtCore/QObject>
#include <QtGui/QTextObjectInterface>

// Qt5: no idea why this definition is not found automatically! It should come
// from <QTextObjectInterface> which resolves to qabstracttextdocumentlayout.h
#ifdef Q_MOC_RUN
Q_DECLARE_INTERFACE(QTextObjectInterface, "org.qt-project.Qt.QTextObjectInterface")
#endif

QT_BEGIN_NAMESPACE
class QPyTextObject : public QObject, public QTextObjectInterface
{
    Q_OBJECT
    Q_INTERFACES(QTextObjectInterface)
public:
    QPyTextObject(QObject *parent = nullptr) : QObject(parent) {}
};
QT_END_NAMESPACE

#endif