代码拉取完成,页面将自动刷新
同步操作将从 码蚁丶/SerialWizard 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
//
// Created by chang on 2021/6/14.
//
#ifndef SERIALWIZARD_DATAPROCESSDIALOG_H
#define SERIALWIZARD_DATAPROCESSDIALOG_H
#include <QDialog>
class QLabel;
class QTextEdit;
class QLineEdit;
class QRadioButton;
class QCheckBox;
class QPushButton;
class DataProcessDialog : public QDialog {
Q_OBJECT
public:
explicit DataProcessDialog(const QString &text="", QWidget *parent = nullptr, Qt::WindowFlags f = Qt::WindowFlags());
~DataProcessDialog() override;
enum class MatchPositionType {
First = 0,
Last,
Middle,
};
enum class LineReturn {
RN = 0,
R,
N,
Space,
None,
Custom
};
QString text();
QString matchText();
int fromIndex();
bool includeMatchText();
int matchPosition();
MatchPositionType matchPositionType();
LineReturn lineReturn();
int matchLineCount();
QList<int> getMatchIndexList();
QStringList getMatchIndexTextList();
protected:
void keyPressEvent(QKeyEvent *) override;
void closeEvent(QCloseEvent *event) override;
void dropEvent(QDropEvent *event) override;
void dragEnterEvent(QDragEnterEvent *event) override;
public Q_SLOT:
void replaceLineReturn();
void splitLine();
private:
void createUi();
void readSettings();
void writeSettings();
void createConnect();
void processText(QString (*p)(DataProcessDialog *, const QString &));
void processText2(bool (*p)(DataProcessDialog *, const QString &));
QTextEdit *textEdit{nullptr};
QLabel *lineCountLabel{nullptr};
QLabel *charCountLabel{nullptr};
QPushButton *simplifiedButton;
QLineEdit *fromIndexLineEdit{nullptr};
QRadioButton *matchFirstRadioButton{nullptr};
QRadioButton *matchLastRadioButton{nullptr};
QRadioButton *matchMiddleRadioButton{nullptr};
QLineEdit *matchPositionLineEdit{nullptr};
QCheckBox *includeMatchTextCheckBox{nullptr};
QLineEdit *matchTextLineEdit{nullptr};
QLineEdit *matchTextCountLineEdit{nullptr};
QPushButton *deleteTextButton{nullptr};
QPushButton *deletePrefixButton{nullptr};
QPushButton *deleteSuffixButton{nullptr};
QPushButton *deleteBeforeButton{nullptr};
QPushButton *deleteAfterButton{nullptr};
QRadioButton *returnTypeRnRadioButton{nullptr};
QRadioButton *returnTypeRRadioButton{nullptr};
QRadioButton *returnTypeNRadioButton{nullptr};
QRadioButton *returnTypeSpaceRadioButton{nullptr};
QRadioButton *returnTypeNoneRadioButton{nullptr};
QRadioButton *returnTypeCustomRadioButton{nullptr};
QLineEdit *customReturnLineEdit{nullptr};
QPushButton *returnTypeReplaceButton{nullptr};
QLineEdit *framePrefixLineEdit{nullptr};
QLineEdit *frameSuffixLineEdit{nullptr};
QPushButton *frameSplitLineButton{nullptr};
QPushButton *deleteShorterLineButton{nullptr};
QPushButton *deleteShorterOrEqualLineButton{nullptr};
QPushButton *deleteLongerLineButton{nullptr};
QPushButton *deleteLongerOrEqualLineButton{nullptr};
QPushButton *deleteMatchTextLineButton{nullptr};
QPushButton *saveMatchTextLineButton{nullptr};
QList<QLineEdit *> indexLineEditList;
QList<QLineEdit *> matchLineEditList;
QPushButton *deleteMatchLineButton{nullptr};
QPushButton *keepMatchLineButton{nullptr};
QPushButton *saveButton{nullptr};
QPushButton *cancelButton{nullptr};
};
#endif //SERIALWIZARD_DATAPROCESSDIALOG_H
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。