Scribus
Open source desktop publishing at your fingertips
pathfinderdialog.h
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 #ifndef PATHFINDERDIALOG_H
8 #define PATHFINDERDIALOG_H
9 
10 #include "pluginapi.h"
11 #include "ui_pathfinderbase.h"
12 #include <QPainterPath>
13 #include <QColor>
14 #include <QList>
15 
16 class PageItem;
17 class ScribusDoc;
18 
19 class PLUGIN_API PathFinderDialog : public QDialog, Ui::PathFinderBase
20 {
21  Q_OBJECT
22 
23 public:
24  PathFinderDialog(QWidget* parent, ScribusDoc* doc, PageItem *shape1, PageItem *shape2);
25  ~PathFinderDialog() {};
26  void updatePreview(QLabel *label, QPainterPath &path, QColor color, double scale);
27  void updatePartPreview(QColor color, double scale);
28  const QString getOtherFillColor();
29  const QString getOtherLineColor();
30 
31  bool keepItem1;
32  bool keepItem2;
33  bool swapped;
34  int opMode;
35  int targetColor;
36 
37  QPainterPath result;
38  QPainterPath result1;
39  QPainterPath result2;
40 private:
41  QColor getColorFromItem(QString color, QColor in);
42 
43  ScribusDoc* m_doc;
44  PageItem* m_source1;
45  PageItem* m_source2;
46 
47  QPainterPath m_input1;
48  QPainterPath m_input2;
49 
50 private slots:
51  void checkKeep();
52  void newOpMode();
53  void swapObjects();
54  void updateAllPreviews();
55  void updateResult();
56 };
57 #endif
Definition: pathfinderdialog.h:19
the Document Class
Definition: scribusdoc.h:90
Definition: pageitem.h:92