inputRejected signal not found

2019-07-27 18:05发布

ALL,

connect(this, &QLineEdit::inputRejected,
        this, &this::my_handler);

Qt 5.7.1 on Gentoo Linux

error: 'inputRejected' is not a member of 'QLineEdit'

Documentation doesn't give any restrictions on that signal.

What is the problem?

TIA!

1条回答
Juvenile、少年°
2楼-- · 2019-07-27 18:30

inputRejected() has been recently introduced in Qt 5.12 so you'll have to update your version of Qt.

  • [QTBUG-57448] Added inputRejected() signal for when a key press is not accepted by the QLineEdit. For instance, when an invalid key is pressed for a validator set.
查看更多
登录 后发表回答