diff --git a/src/utils/regex-config.cpp b/src/utils/regex-config.cpp index 5b4bcdae..69e5651d 100644 --- a/src/utils/regex-config.cpp +++ b/src/utils/regex-config.cpp @@ -47,6 +47,13 @@ RegexConfig::GetRegularExpression(const std::string &expr) const return GetRegularExpression(QString::fromStdString(expr)); } +RegexConfig RegexConfig::PartialMatchRegexConfig() +{ + RegexConfig conf; + conf._partialMatch = true; + return conf; +} + RegexConfigWidget::RegexConfigWidget(QWidget *parent) : QWidget(parent), _openSettings(new QPushButton()), diff --git a/src/utils/regex-config.hpp b/src/utils/regex-config.hpp index 7082c33f..59b5e9a9 100644 --- a/src/utils/regex-config.hpp +++ b/src/utils/regex-config.hpp @@ -25,6 +25,8 @@ public: QRegularExpression GetRegularExpression(const QString &) const; QRegularExpression GetRegularExpression(const std::string &) const; + static RegexConfig PartialMatchRegexConfig(); + private: bool _enable = false; bool _partialMatch = false;