I have a QLineEdit
with an InputMask
set to ">AAAA90"
, that is, I expect the text to consists of exactly 4 uppercase Ascii letters and between 1-2 digits. If the user types "AA1" however, the QLineEdit
will show AA 1
, namely it will insert two blanks and print the "1" which is permitted in the 5th position. I would rather want a behavior like with illegal characters at any position, namely if the user types "AA%" then the cursor stays at the third position and does not print the "%" character.
Is this possible in QT5?