-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathqcpl_format_graph.h
56 lines (41 loc) · 1.02 KB
/
qcpl_format_graph.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
#ifndef QCPL_FORMAT_GRAPH_H
#define QCPL_FORMAT_GRAPH_H
#include <QWidget>
#include <QJsonObject>
QT_BEGIN_NAMESPACE
class QSpinBox;
class QToolButton;
QT_END_NAMESPACE
namespace Ori {
namespace Widgets {
class MenuToolButton;
class BaseColorButton;
}}
class QCPGraph;
namespace QCPL {
class PenEditorWidget;
class ColorButton;
class GraphFormatWidget : public QWidget
{
Q_OBJECT
public:
explicit GraphFormatWidget(QCPGraph *graph);
// Required for genericFormatDlg()
bool needSaveDefault() const { return false; }
void populate();
public slots:
void apply();
void restore();
private:
QCPGraph *_graph;
QJsonObject _backup;
PenEditorWidget *_linePen, *_markerPen;
QSpinBox *_markerSize, *_markerSkip;
Ori::Widgets::MenuToolButton *_markerShape;
Ori::Widgets::BaseColorButton *_markerColor;
void createMarkerShapeAction(int shape, const QString& title);
void selectMarkerColor();
void setMarkerColor(const QColor& c);
};
} // namespace QCPL
#endif // QCPL_FORMAT_GRAPH_H