-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathwidgetuistyle.h
69 lines (57 loc) · 1.64 KB
/
widgetuistyle.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
57
58
59
60
61
62
63
64
65
66
67
68
69
#ifndef WIDGETUISTYLE_H
#define WIDGETUISTYLE_H
#include "src/coreEditor/coreeditor.h"
#include <QWidget>
#include <QDialog>
#include <QBuffer>
#include <QString>
#include <QPushButton>
#include <QGraphicsScene>
#include <QFileDialog>
#include <QFile>
#include <QIODevice>
#include <QHBoxLayout>
#include <QVBoxLayout>
#include <QBoxLayout>
#include <QGraphicsProxyWidget>
#include <QGraphicsItem>
#include <QList>
#include <QDir>
#include <QtUiTools/QUiLoader>
namespace Ui {
class WidgetUiStyle;
}
class WidgetUiStyle : public QWidget
{
Q_OBJECT
public:
explicit WidgetUiStyle(QWidget* parent = nullptr);
~WidgetUiStyle() override;
QBuffer* getBufferUi() const;
QBuffer* createBufferUi();
void setBufferUi(QBuffer* buffer);
public slots:
void setStyleSheetWidget(const QString& style);
private slots:
void openUI();
void showFull();
private:
class ShowFullWidgetUi : public QDialog
{
public:
ShowFullWidgetUi(QWidget* parent = nullptr);
~ShowFullWidgetUi() override = default;
void setViewWidgetUi(QBuffer* bufferUi);
void setStyleSheetDialog(const QString& style);
private:
QWidget *m_view = nullptr;
QPushButton *m_close = new QPushButton("Закрыть");
};
Ui::WidgetUiStyle *ui = nullptr;
QGraphicsScene *m_scene = new QGraphicsScene(this);
QBuffer *m_bufferUi = new QBuffer(this);
CoreEditor *m_editor = nullptr;
ShowFullWidgetUi *m_showFull = new ShowFullWidgetUi(this);
void createWidgetUi();
};
#endif // WIDGETUISTYLE_H