KeyboardVariant enum

Which keyboard a field asked for — what a platform draws, not only how tall it is.

Two facts wear one name here, and they are genuinely separate. The height differs by platform: an iPhone gives a keypad 27–45 fewer points than a QWERTY, an iPad gives every type the same keyboard, and Gboard swaps the layout without moving the height at all. The picture differs everywhere — a number pad looks nothing like a letter keyboard on any device. So a variant always changes what is drawn, and changes the height only where the device has a measurement saying it should.

Here rather than beside the guest that reads it, for the reason KeyboardMode and ScreenOrientation are: this is a fact about the device, and the code that maps a TextInputType onto it must not have to import Flutter.

Inheritance
Available extensions

Values

letters → const KeyboardVariant

The full letter keyboard, and what most fields get.

email → const KeyboardVariant

Letters with an @ and a dot on the bottom row.

url → const KeyboardVariant

Letters with a slash and a .com.

keypad → const KeyboardVariant

A digit pad — a grid of numbers rather than rows of letters.

Properties

hashCode → int
The hash code for this object.
no setterinherited
index → int
A numeric identifier for the enumerated value.
no setterinherited
name → String

Available on Enum, provided by the EnumName extension

The name of the enum value.
no setter
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Constants

values → const List<KeyboardVariant>
A constant List of the values in this enum, in order of their declaration.