Mercurial > hg > syntilista
changeset 284:ea0513940991
Change QRegExp to QRegularExpression.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Tue, 09 May 2023 11:11:10 +0300 |
parents | 958451fcd85a |
children | 6f5d2028b882 |
files | src/main.cpp |
diffstat | 1 files changed, 3 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/main.cpp Tue May 09 11:03:00 2023 +0300 +++ b/src/main.cpp Tue May 09 11:11:10 2023 +0300 @@ -10,6 +10,7 @@ #include <QMessageBox> #include <QSettings> #include <QStandardPaths> +#include <QRegularExpression> #include "main.h" #include "ui_mainwindow.h" #include "ui_aboutwindow.h" @@ -278,8 +279,8 @@ showFullScreen(); // Validator for amount input - QRegExp vregex("\\d{0,4}[,.]\\d{0,2}|\\d{0,4}"); - ui->edit_Amount->setValidator(new QRegExpValidator(vregex, this)); + QRegularExpression vregex("\\d{0,4}[,.]\\d{0,2}|\\d{0,4}"); + ui->edit_Amount->setValidator(new QRegularExpressionValidator(vregex, this)); // Setup person list filtering and sorting peopleSortIndex = 1;