[Interest] How to hide keyboard while clicking outside of keyboard in qml
Gian Maxera
gmaxera at gmail.com
Wed Feb 24 10:35:33 CET 2016
Hello,
I do in this way:
- add a MouseArea covering the entire screen that got a z level lower than any other input area (like TextArea)
- on the onClicked I just call: Qt.inputMethod.hide() and the keyboard will close is you click outside any other active elements.
Ciao,
Gianluca.
> On 24 Feb 2016, at 09:32, 黄裔 <huang_yi at cdv.com> wrote:
>
> I use TextArea as input in qml file. When clicking TextArea, keyboard pops up. But the keyboard could not hide while clicking outside of it. Whether there is a method or any API in qml can resolve this problem conveniently?
>
> thanks.
> Yi
> _______________________________________________
> Interest mailing list
> Interest at qt-project.org
> http://lists.qt-project.org/mailman/listinfo/interest
More information about the Interest
mailing list