55 lines
1.3 KiB
C
55 lines
1.3 KiB
C
|
#ifndef WORDSINPUTDIALOG_H
|
|||
|
#define WORDSINPUTDIALOG_H
|
|||
|
|
|||
|
#include <QDialog>
|
|||
|
#include "mybutton.h"
|
|||
|
#include "setcontrolstyle.h"
|
|||
|
|
|||
|
namespace Ui {
|
|||
|
class WordsInputDialog;
|
|||
|
}
|
|||
|
|
|||
|
class WordsInputDialog : public QDialog
|
|||
|
{
|
|||
|
Q_OBJECT
|
|||
|
|
|||
|
public:
|
|||
|
explicit WordsInputDialog(QWidget *parent = 0);
|
|||
|
~WordsInputDialog();
|
|||
|
|
|||
|
private:
|
|||
|
Ui::WordsInputDialog *ui;
|
|||
|
|
|||
|
private:
|
|||
|
void setInputStr(QString str);//设置字符
|
|||
|
|
|||
|
private:
|
|||
|
void initControl();//初始化窗体控件,包括位置、尺寸、样式
|
|||
|
void initResolution1910();//初始化窗体控件为1920x1080分辨率
|
|||
|
void initResolution1006();//初始化窗体控件为1024x600分辨率
|
|||
|
void initControlStyle();//初始化窗体控件样式
|
|||
|
|
|||
|
private:
|
|||
|
QList <QPushButton *> m_buttonCharacterList;
|
|||
|
QList <QPushButton *> m_buttonWordList;
|
|||
|
QList <QPushButton *> m_buttonNumberList;
|
|||
|
int m_shift; //-1:字母小写 1:字母大写
|
|||
|
QString m_inputStr;//输入的字符
|
|||
|
|
|||
|
public:
|
|||
|
void setTitleStr(QString str);//设置标题
|
|||
|
void setOldWordsStr(QString str);//设置标题
|
|||
|
void clean();
|
|||
|
void wifiClean();
|
|||
|
QString getInputStr();//获取输入的字符
|
|||
|
|
|||
|
private slots:
|
|||
|
void inputBtnClick();
|
|||
|
void on_buttonShift_clicked();
|
|||
|
void on_buttonBack_clicked();
|
|||
|
void on_buttonOk_clicked();
|
|||
|
void on_buttonCancel_clicked();
|
|||
|
};
|
|||
|
|
|||
|
#endif // WORDSINPUTDIALOG_H
|