diff options
author | Lars Knoll <lars.knoll@qt.io> | 2020-02-28 08:40:53 +0100 |
---|---|---|
committer | Lars Knoll <lars.knoll@qt.io> | 2020-02-28 09:48:30 +0100 |
commit | a450cce6b670dbcac84fcc4a66fc632b31ce8414 (patch) | |
tree | 35b77fa22c4def97b619bd3a87f6d394e452bb2e /src/widgets/widgets/qlineedit.cpp | |
parent | f6f6eab89f57fb0db8f623f4a92a7b9c4ba6e9ea (diff) | |
parent | 4c86e667d220e27bb4b6e370675ffb2872e8521c (diff) |
Merge remote-tracking branch 'origin/5.15' into dev
Change-Id: I469b0501cc65fc5ce4d797a69ae89405cc69c7f8
Diffstat (limited to 'src/widgets/widgets/qlineedit.cpp')
-rw-r--r-- | src/widgets/widgets/qlineedit.cpp | 28 |
1 files changed, 16 insertions, 12 deletions
diff --git a/src/widgets/widgets/qlineedit.cpp b/src/widgets/widgets/qlineedit.cpp index 9faf161cb1..0ba3611cfd 100644 --- a/src/widgets/widgets/qlineedit.cpp +++ b/src/widgets/widgets/qlineedit.cpp @@ -1202,8 +1202,8 @@ QMargins QLineEdit::textMargins() const The input mask is an input template string. It can contain the following elements: \table - \row \li Mask Characters \li Defines the class of input characters that are - considered valid in this position + \row \li Mask Characters \li Defines the \l {QChar::} {Category} of input characters + that are considered valid in this position \row \li Meta Characters \li Various special meanings \row \li Separators \li All other characters are regarded as immutable separators \endtable @@ -1212,17 +1212,21 @@ QMargins QLineEdit::textMargins() const \table \header \li Mask Character \li Meaning - \row \li \c A \li ASCII alphabetic character required. A-Z, a-z. - \row \li \c a \li ASCII alphabetic character permitted but not required. - \row \li \c N \li ASCII alphanumeric character required. A-Z, a-z, 0-9. - \row \li \c n \li ASCII alphanumeric character permitted but not required. + \row \li \c A \li character of the Letter category required, such as A-Z, a-z. + \row \li \c a \li character of the Letter category permitted but not required. + \row \li \c N \li character of the Letter or Number category required, such as + A-Z, a-z, 0-9. + \row \li \c n \li character of the Letter or Number category permitted but not required. \row \li \c X \li Any non-blank character required. \row \li \c x \li Any non-blank character permitted but not required. - \row \li \c 9 \li ASCII digit required. 0-9. - \row \li \c 0 \li ASCII digit permitted but not required. - \row \li \c D \li ASCII digit required. 1-9. - \row \li \c d \li ASCII digit permitted but not required (1-9). - \row \li \c # \li ASCII digit or plus/minus sign permitted but not required. + \row \li \c 9 \li character of the Number category required, e.g 0-9. + \row \li \c 0 \li character of the Number category permitted but not required. + \row \li \c D \li character of the Number category and larger than zero required, + such as 1-9 + \row \li \c d \li character of the Number category and larger than zero permitted but not + required, such as 1-9. + \row \li \c # \li character of the Number category, or plus/minus sign permitted but not + required. \row \li \c H \li Hexadecimal character required. A-F, a-f, 0-9. \row \li \c h \li Hexadecimal character permitted but not required. \row \li \c B \li Binary character required. 0-1. @@ -1264,7 +1268,7 @@ QMargins QLineEdit::textMargins() const To get range control (e.g., for an IP address) use masks together with \l{setValidator()}{validators}. - \sa maxLength + \sa maxLength, QChar::isLetter(), QChar::isNumber(), QChar::digitValue() */ QString QLineEdit::inputMask() const { |