CreateSchemeWidget.h 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. #ifndef CREATESCHEMEWIDGET_H
  2. #define CREATESCHEMEWIDGET_H
  3. #include <QDialog>
  4. class PushButton;
  5. class LineEdit;
  6. class TextEdit;
  7. class QVBoxLayout;
  8. class QGridLayout;
  9. class QHBoxLayout;
  10. class QLabel;
  11. class LineEdit;
  12. class CreateSchemeWidget : public QDialog
  13. {
  14. Q_OBJECT
  15. public:
  16. explicit CreateSchemeWidget(QWidget *parent = nullptr);
  17. void clearInputs();
  18. private:
  19. void showEvent(QShowEvent *e) override;
  20. void initWindow();
  21. void initialize();
  22. void initLayout();
  23. void connectSignalsAndSlots();
  24. private slots:
  25. void slotSelectPic();
  26. void slotContentChanged();
  27. void slotConfirmed();
  28. signals:
  29. void sigSchemeInfoConfirmed(const QString name, const QString remark, const QString path);
  30. private:
  31. QVBoxLayout *m_vBoxLayout = nullptr;
  32. QGridLayout *m_gridLayout = nullptr;
  33. QLabel *m_nameLabel = nullptr;
  34. LineEdit *m_nameEdit = nullptr;
  35. QLabel *m_schemeLabel = nullptr;
  36. TextEdit *m_schemeEdit = nullptr;
  37. PushButton *m_picButton = nullptr;
  38. LineEdit *m_picLine = nullptr;
  39. QHBoxLayout *m_hBoxLayout = nullptr;
  40. PushButton *m_confirButton = nullptr;
  41. };
  42. #endif // CREATESCHEMEWIDGET_H