diff options
author | w0xlt <94266259+w0xlt@users.noreply.github.com> | 2022-06-21 19:11:54 -0300 |
---|---|---|
committer | w0xlt <94266259+w0xlt@users.noreply.github.com> | 2022-06-21 19:19:18 -0300 |
commit | ace9af5688662a56d855bd26f36bc5c145b909e3 (patch) | |
tree | b0a93c766a5cf1558fbb73bc80448786bfd0d1f4 /src/qt/utilitydialog.cpp | |
parent | c378535e28e0c54353fde9c4a66cb3134a3ee742 (diff) |
qt: Replace `QRegExp` with `QRegularExpression`
Co-authored-by: Pavol Rusnak <pavol@rusnak.io>
Co-authored-by: Jarol Rodriguez <jarolrod@tutanota.com>
Diffstat (limited to 'src/qt/utilitydialog.cpp')
-rw-r--r-- | src/qt/utilitydialog.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/qt/utilitydialog.cpp b/src/qt/utilitydialog.cpp index e68095f8e5..4894cac905 100644 --- a/src/qt/utilitydialog.cpp +++ b/src/qt/utilitydialog.cpp @@ -22,7 +22,8 @@ #include <QCloseEvent> #include <QLabel> #include <QMainWindow> -#include <QRegExp> +#include <QRegularExpression> +#include <QString> #include <QTextCursor> #include <QTextTable> #include <QVBoxLayout> @@ -44,9 +45,8 @@ HelpMessageDialog::HelpMessageDialog(QWidget *parent, bool about) : /// HTML-format the license message from the core QString licenseInfoHTML = QString::fromStdString(LicenseInfo()); // Make URLs clickable - QRegExp uri("<(.*)>", Qt::CaseSensitive, QRegExp::RegExp2); - uri.setMinimal(true); // use non-greedy matching - licenseInfoHTML.replace(uri, "<a href=\"\\1\">\\1</a>"); + QRegularExpression uri(QStringLiteral("<(.*)>"), QRegularExpression::InvertedGreedinessOption); + licenseInfoHTML.replace(uri, QStringLiteral("<a href=\"\\1\">\\1</a>")); // Replace newlines with HTML breaks licenseInfoHTML.replace("\n", "<br>"); |