1/*
2 xcf.cpp: A Qt 5 plug-in for reading GIMP XCF image files
3 SPDX-FileCopyrightText: 2001 lignum Computing Inc. <allen@lignumcomputing.com>
4 SPDX-FileCopyrightText: 2004 Melchior FRANZ <mfranz@kde.org>
5
6 SPDX-License-Identifier: LGPL-2.1-or-later
7*/
8
9#ifndef KIMG_XCF_P_H
10#define KIMG_XCF_P_H
11
12#include <QImageIOPlugin>
13
14class XCFHandler : public QImageIOHandler
15{
16public:
17 XCFHandler();
18
19 bool canRead() const override;
20 bool read(QImage *image) override;
21 bool write(const QImage &image) override;
22
23 bool supportsOption(QImageIOHandler::ImageOption option) const override;
24 QVariant option(QImageIOHandler::ImageOption option) const override;
25
26 static bool canRead(QIODevice *device);
27};
28
29class XCFPlugin : public QImageIOPlugin
30{
31 Q_OBJECT
32 Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QImageIOHandlerFactoryInterface" FILE "xcf.json")
33
34public:
35 Capabilities capabilities(QIODevice *device, const QByteArray &format) const override;
36 QImageIOHandler *create(QIODevice *device, const QByteArray &format = QByteArray()) const override;
37};
38
39#endif // KIMG_XCF_P_H
40

source code of kimageformats/src/imageformats/xcf_p.h