C

EnterKeyAction QML Type

Provides attached properties for customizing the enter key. More...

Import Statement: import QtQuick.VirtualKeyboard

Attached Properties

Detailed Description

The EnterKeyAction type provides attached properties which allows customizing the enter key button of the keyboard.

The EnterKeyAction must be used directly inside the item receiving input focus, such as TextInput.

For example:

TextInput {
    id: textInput1
    EnterKeyAction.actionId: EnterKeyAction.Next
    Keys.onPressed: {
        onAccepted: {
            // transfer focus to second TextInput when Enter pressed
            textInput2.forceActiveFocus()
        }
        ...
    }
}

Attached Property Documentation

EnterKeyAction.actionId : int

Sets the action id for the enter key in virtual keyboard. When the action id is set, it affects the icon for the enter key.

ConstantDescription
EnterKeyAction.NoneNo action defined.
EnterKeyAction.GoAction performs go operation. For example, load the entered URL.
EnterKeyAction.SearchAction performs search operation.
EnterKeyAction.SendAction sends the entered text.
EnterKeyAction.NextAction moves the input focus to the next field accepting text input.
EnterKeyAction.DoneSame as EnterKeyAction.Next, except all the text input is done.

Available under certain Qt licenses.
Find out more.