okular/generators/plucker/generator_plucker.h
Albert Astals Cid a2576dc746 Act on core/ TODOs that are not binary compatible
I'm going to need to break binary compatibility to add a new feature
so may as well cleanup all the TODOs regarding that

Changes:
 * Moving a few destructors to the header
 * Removing a few unnecessary & in params
 * Adding a few necessary & in params
 * Making print return an enum instead of a bool and then having another
   function that returns the enum
 * Make Generator::requestFontData be a virtual
 * Remove unused enum
 * Remove a few filePrinter unneeded functions
 * Remove unused TextDocumentGenerator::addMetaData signal
2021-12-29 09:35:25 +00:00

51 lines
1.3 KiB
C++

/*
SPDX-FileCopyrightText: 2007 Tobias Koenig <tokoe@kde.org>
SPDX-License-Identifier: GPL-2.0-or-later
*/
#ifndef _OKULAR_GENERATOR_PLUCKER_H_
#define _OKULAR_GENERATOR_PLUCKER_H_
#include <core/document.h>
#include <core/generator.h>
#include <QTextBlock>
#include "qunpluck.h"
class QTextDocument;
class PluckerGenerator : public Okular::Generator
{
Q_OBJECT
Q_INTERFACES(Okular::Generator)
public:
PluckerGenerator(QObject *parent, const QVariantList &args);
~PluckerGenerator() override;
// [INHERITED] load a document and fill up the pagesVector
bool loadDocument(const QString &fileName, QVector<Okular::Page *> &pagesVector) override;
// [INHERITED] document information
Okular::DocumentInfo generateDocumentInfo(const QSet<Okular::DocumentInfo::Key> &keys) const override;
// [INHERITED] perform actions on document / pages
QImage image(Okular::PixmapRequest *request) override;
// [INHERITED] text exporting
Okular::ExportFormat::List exportFormats() const override;
bool exportTo(const QString &fileName, const Okular::ExportFormat &format) override;
protected:
bool doCloseDocument() override;
private:
QList<QTextDocument *> mPages;
QSet<int> mLinkAdded;
Link::List mLinks;
Okular::DocumentInfo mDocumentInfo;
};
#endif