Changing RegExpValidator to RegularExpressionValidator.

This commit is contained in:
Adsooi 2023-05-21 22:32:49 +02:00
parent 98f26d4919
commit 78ffc8c645
Signed by: Ad5001
GPG key ID: EF45F9C6AFE20160
2 changed files with 6 additions and 6 deletions

View file

@ -140,8 +140,8 @@ Column {
visible: control.dictionaryMode visible: control.dictionaryMode
height: parent.height height: parent.height
width: visible ? 50 : 0 width: visible ? 50 : 0
validator: RegExpValidator { validator: RegularExpressionValidator {
regExp: control.keyRegexp regularExpression: control.keyRegexp
} }
verticalAlignment: TextInput.AlignVCenter verticalAlignment: TextInput.AlignVCenter
horizontalAlignment: TextInput.AlignHCenter horizontalAlignment: TextInput.AlignHCenter
@ -180,8 +180,8 @@ Column {
id: valueInput id: valueInput
height: parent.height height: parent.height
width: parent.width - x - deleteButton.width - 5 width: parent.width - x - deleteButton.width - 5
validator: RegExpValidator { validator: RegularExpressionValidator {
regExp: control.valueRegexp regularExpression: control.valueRegexp
} }
verticalAlignment: TextInput.AlignVCenter verticalAlignment: TextInput.AlignVCenter
horizontalAlignment: TextInput.AlignHCenter horizontalAlignment: TextInput.AlignHCenter

View file

@ -113,8 +113,8 @@ Item {
verticalAlignment: TextInput.AlignVCenter verticalAlignment: TextInput.AlignVCenter
horizontalAlignment: control.label == "" ? TextInput.AlignLeft : TextInput.AlignHCenter horizontalAlignment: control.label == "" ? TextInput.AlignLeft : TextInput.AlignHCenter
color: sysPalette.windowText color: sysPalette.windowText
validator: RegExpValidator { validator: RegularExpressionValidator {
regExp: control.isInt ? /-?[0-9]+/ : control.isDouble ? /-?[0-9]+(\.[0-9]+)?/ : /.+/ regularExpression: control.isInt ? /-?[0-9]+/ : control.isDouble ? /-?[0-9]+(\.[0-9]+)?/ : /.+/
} }
focus: true focus: true
text: control.defValue text: control.defValue