1 /* 2 For general Scribus (>=1.3.2) copyright and licensing information please refer 3 to the COPYING file provided with the program. Following this notice may exist 4 a copyright and/or license notice that predates the release of Scribus 1.3.2 5 for which a new license (GPL+exception) is in place. 6 */ 7 8 #ifndef BARCODEGENERATORRENDERTHREAD_H 9 #define BARCODEGENERATORRENDERTHREAD_H 10 11 #include <QString> 12 #include <QThread> 13 #include <QMutex> 14 #include <QWaitCondition> 15 16 class BarcodeGeneratorRenderThread : public QThread 17 { 18 Q_OBJECT 19 20 public: 21 BarcodeGeneratorRenderThread(QObject* parent = nullptr); 22 ~BarcodeGeneratorRenderThread(); 23 void render(const QString&); 24 25 signals: 26 void renderedImage(QString); 27 28 protected: 29 void run(); 30 31 private: 32 QMutex mutex; 33 QWaitCondition condition; 34 QString psCommand; 35 bool restart; 36 bool abort; 37 38 }; 39 40 #endif 41