23class QPdfIOHandler :
public QImageIOHandler
27 ~QPdfIOHandler() override;
28 bool canRead()
const override;
29 static bool canRead(QIODevice *device);
30 int currentImageNumber()
const override;
31 QRect currentImageRect()
const override;
32 int imageCount()
const override;
33 bool read(QImage *image) override;
34 QVariant option(ImageOption option)
const override;
35 void setOption(ImageOption option,
const QVariant & value) override;
36 bool supportsOption(ImageOption option)
const override;
37 bool jumpToImage(
int frame) override;
38 bool jumpToNextImage() override;
41 bool load(QIODevice *device);
44 QPointer<QPdfDocument> m_doc;
49 QRect m_scaledClipRect;
50 QColor m_backColor = Qt::transparent;
51 bool m_loaded =
false;
52 bool m_ownsDocument =
false;
QImageIOHandler * create(QIODevice *device, const QByteArray &format=QByteArray()) const override
Creates and returns a QImageIOHandler subclass, with device and format set.