Considering:
TextInput and TextEdit's openSoftwareInputPanel() and closeSoftwareInputPanel() methods have been removed. Use the new Qt.inputMethod property and call Qt.inputMethod.show() Qt.inputMethod.hide() to show and hide the virtual keyboard.
from: http://doc.qt.io/qt-5/qtquick-porting-qt5.html
import QtQuick 2.3
import QtQuick.Window 2.2
Window
{
id: root
visible: true
width: 600
height: 557
Rectangle
{
id: numberInputBox
height: 500
width: 300
border.color: "green"
TextInput
{
id: textInput
font.pixelSize: 20
cursorVisible: true
height: 500
width: 300
MouseArea
{
anchors.fill: parent
onClicked:
{
Qt.inputMethod.show()
console.log("getPrinted")
}
}
}
}
}
import QtQuick 2.3
import QtQuick.Window 2.2
Window
{
id: root
visible: true
width: 600
height: 557
Rectangle
{
id: numberInputBox
height: 500
width: 300
border.color: "green"
TextInput
{
id: textInput
font.pixelSize: 20
cursorVisible: true
height: 500
width: 300
MouseArea
{
anchors.fill: parent
onClicked:
{
Qt.inputMethod.show()
console.log("getPrinted")
}
}
}
}
}
To copy to clipboard, switch view to plain text mode
The text from console.log gets printed but I cannot see any keyboard on screen.
Bookmarks