File indexing completed on 2025-01-26 04:10:56

0001 /*
0002  *  SPDX-FileCopyrightText: 2005 Cyrille Berger <cberger@cberger.net>
0003  *
0004  *  SPDX-License-Identifier: GPL-2.0-or-later
0005  */
0006 
0007 #ifndef _KIS_JPEG_EXPORT_H_
0008 #define _KIS_JPEG_EXPORT_H_
0009 
0010 #include <QVariant>
0011 
0012 #include <KisImportExportFilter.h>
0013 #include <kis_config_widget.h>
0014 #include "ui_kis_wdg_options_jpeg.h"
0015 #include <kis_meta_data_store.h>
0016 #include <kis_meta_data_filter_registry_model.h>
0017 
0018 
0019 class KisWdgOptionsJPEG : public KisConfigWidget, public Ui::WdgOptionsJPEG
0020 {
0021     Q_OBJECT
0022 
0023 public:
0024     KisWdgOptionsJPEG(QWidget *parent);
0025     void setConfiguration(const KisPropertiesConfigurationSP  cfg) override;
0026     KisPropertiesConfigurationSP configuration() const override;
0027 private:
0028     KisMetaData::FilterRegistryModel m_filterRegistryModel;
0029 };
0030 
0031 
0032 class KisJPEGExport : public KisImportExportFilter
0033 {
0034     Q_OBJECT
0035 public:
0036     KisJPEGExport(QObject *parent, const QVariantList &);
0037     ~KisJPEGExport() override;
0038 public:
0039     KisImportExportErrorCode convert(KisDocument *document, QIODevice *io,  KisPropertiesConfigurationSP configuration = 0) override;
0040     KisPropertiesConfigurationSP defaultConfiguration(const QByteArray& from = "", const QByteArray& to = "") const override;
0041     KisConfigWidget *createConfigurationWidget(QWidget *parent, const QByteArray& from = "", const QByteArray& to = "") const override;
0042     void initializeCapabilities() override;
0043 };
0044 
0045 #endif