Plugin metasystem

This commit is contained in:
Jakub Melka
2020-11-17 18:28:34 +01:00
parent 1189d864f6
commit 4c410374db
17 changed files with 529 additions and 8 deletions

View File

@@ -0,0 +1,7 @@
{
"Name" : "Dimensions",
"Author" : "Jakub Melka",
"Version" : "1.0.0",
"License" : "LGPL v3",
"Description" : "Measure distances, area, perimeter in a document page."
}

View File

@@ -0,0 +1,42 @@
# Copyright (C) 2020 Jakub Melka
#
# This file is part of PdfForQt.
#
# PdfForQt is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# PdfForQt is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public License
# along with PDFForQt. If not, see <https://www.gnu.org/licenses/>.
TEMPLATE = lib
DEFINES += DIMENSIONPLUGIN_LIBRARY
LIBS += -L$$OUT_PWD/../..
LIBS += -lPDFForQtLib
QMAKE_CXXFLAGS += /std:c++latest /utf-8
INCLUDEPATH += $$PWD/../../PDFForQtLib/Sources
DESTDIR = $$OUT_PWD/../../pdfplugins
CONFIG += c++11
SOURCES += \
dimensionsplugin.cpp
HEADERS += \
dimensionsplugin.h
CONFIG += force_debug_info
DISTFILES += \
DimensionsPlugin.json

View File

@@ -0,0 +1,12 @@
#include "dimensionsplugin.h"
namespace pdfplugin
{
DimensionsPlugin::DimensionsPlugin() :
pdf::PDFPlugin(nullptr)
{
}
}

View File

@@ -0,0 +1,22 @@
#ifndef DIMENSIONSPLUGIN_H
#define DIMENSIONSPLUGIN_H
#include "pdfplugin.h"
#include <QObject>
namespace pdfplugin
{
class DimensionsPlugin : public pdf::PDFPlugin
{
Q_OBJECT
Q_PLUGIN_METADATA(IID "PdfForQt.DimensionsPlugin" FILE "DimensionsPlugin.json")
public:
DimensionsPlugin();
};
} // namespace pdfplugin
#endif // DIMENSIONSPLUGIN_H