KeyType enum

Types of keyboard input events.

Used to categorize parsed key events into semantic categories.

Extended Keys

This enum supports function keys F1-F63, media keys, lock keys, and modifier-only keys from the Kitty keyboard protocol.

Example:

switch (key.type) {
  case KeyType.f21:
    // Handle F21
    break;
  case KeyType.mediaPlay:
    // Handle media play
    break;
  // ...
}
Inheritance
Available extensions

Values

runes → const KeyType

Regular character input (letters, numbers, symbols).

The actual character(s) are available in Key.runes.

enter → const KeyType

Enter/Return key.

tab → const KeyType

Tab key.

backspace → const KeyType

Backspace key.

delete → const KeyType

Delete key.

escape → const KeyType

Escape key.

space → const KeyType

Space key (when treated as special rather than rune).

up → const KeyType

Up arrow key.

down → const KeyType

Down arrow key.

left → const KeyType

Left arrow key.

Right arrow key.

home → const KeyType

Home key.

end → const KeyType

End key.

pageUp → const KeyType

Page Up key.

pageDown → const KeyType

Page Down key.

insert → const KeyType

Insert key.

f1 → const KeyType

F1 function key.

f2 → const KeyType

F2 function key.

f3 → const KeyType

F3 function key.

f4 → const KeyType

F4 function key.

f5 → const KeyType

F5 function key.

f6 → const KeyType

F6 function key.

f7 → const KeyType

F7 function key.

f8 → const KeyType

F8 function key.

f9 → const KeyType

F9 function key.

f10 → const KeyType

F10 function key.

f11 → const KeyType

F11 function key.

f12 → const KeyType

F12 function key.

f13 → const KeyType

F13 function key (extended).

f14 → const KeyType

F14 function key (extended).

f15 → const KeyType

F15 function key (extended).

f16 → const KeyType

F16 function key (extended).

f17 → const KeyType

F17 function key (extended).

f18 → const KeyType

F18 function key (extended).

f19 → const KeyType

F19 function key (extended).

f20 → const KeyType

F20 function key (extended).

f21 → const KeyType

F21 function key (Kitty protocol).

f22 → const KeyType

F22 function key (Kitty protocol).

f23 → const KeyType

F23 function key (Kitty protocol).

f24 → const KeyType

F24 function key (Kitty protocol).

f25 → const KeyType

F25 function key (Kitty protocol).

f26 → const KeyType

F26 function key (Kitty protocol).

f27 → const KeyType

F27 function key (Kitty protocol).

f28 → const KeyType

F28 function key (Kitty protocol).

f29 → const KeyType

F29 function key (Kitty protocol).

f30 → const KeyType

F30 function key (Kitty protocol).

f31 → const KeyType

F31 function key (Kitty protocol).

f32 → const KeyType

F32 function key (Kitty protocol).

f33 → const KeyType

F33 function key (Kitty protocol).

f34 → const KeyType

F34 function key (Kitty protocol).

f35 → const KeyType

F35 function key (Kitty protocol).

f36 → const KeyType

F36 function key (Kitty protocol).

f37 → const KeyType

F37 function key (Kitty protocol).

f38 → const KeyType

F38 function key (Kitty protocol).

f39 → const KeyType

F39 function key (Kitty protocol).

f40 → const KeyType

F40 function key (Kitty protocol).

f41 → const KeyType

F41 function key (Kitty protocol).

f42 → const KeyType

F42 function key (Kitty protocol).

f43 → const KeyType

F43 function key (Kitty protocol).

f44 → const KeyType

F44 function key (Kitty protocol).

f45 → const KeyType

F45 function key (Kitty protocol).

f46 → const KeyType

F46 function key (Kitty protocol).

f47 → const KeyType

F47 function key (Kitty protocol).

f48 → const KeyType

F48 function key (Kitty protocol).

f49 → const KeyType

F49 function key (Kitty protocol).

f50 → const KeyType

F50 function key (Kitty protocol).

f51 → const KeyType

F51 function key (Kitty protocol).

f52 → const KeyType

F52 function key (Kitty protocol).

f53 → const KeyType

F53 function key (Kitty protocol).

f54 → const KeyType

F54 function key (Kitty protocol).

f55 → const KeyType

F55 function key (Kitty protocol).

f56 → const KeyType

F56 function key (Kitty protocol).

f57 → const KeyType

F57 function key (Kitty protocol).

f58 → const KeyType

F58 function key (Kitty protocol).

f59 → const KeyType

F59 function key (Kitty protocol).

f60 → const KeyType

F60 function key (Kitty protocol).

f61 → const KeyType

F61 function key (Kitty protocol).

f62 → const KeyType

F62 function key (Kitty protocol).

f63 → const KeyType

F63 function key (Kitty protocol).

capsLock → const KeyType

Caps Lock key.

scrollLock → const KeyType

Scroll Lock key.

numLock → const KeyType

Num Lock key.

printScreen → const KeyType

Print Screen key.

pause → const KeyType

Pause/Break key.

Menu/Application key.

mediaPlay → const KeyType

Media Play key.

mediaPause → const KeyType

Media Pause key.

mediaPlayPause → const KeyType

Media Play/Pause toggle key.

mediaReverse → const KeyType

Media Reverse key.

mediaStop → const KeyType

Media Stop key.

mediaFastForward → const KeyType

Media Fast Forward key.

mediaRewind → const KeyType

Media Rewind key.

mediaNext → const KeyType

Media Next Track key.

mediaPrev → const KeyType

Media Previous Track key.

mediaRecord → const KeyType

Media Record key.

volumeDown → const KeyType

Volume Down key.

volumeUp → const KeyType

Volume Up key.

mute → const KeyType

Mute key.

leftShift → const KeyType

Left Shift key (standalone press).

leftAlt → const KeyType

Left Alt key (standalone press).

leftCtrl → const KeyType

Left Control key (standalone press).

leftSuper → const KeyType

Left Super/Windows/Command key (standalone press).

leftHyper → const KeyType

Left Hyper key (standalone press).

leftMeta → const KeyType

Left Meta key (standalone press).

rightShift → const KeyType

Right Shift key (standalone press).

rightAlt → const KeyType

Right Alt key (standalone press).

rightCtrl → const KeyType

Right Control key (standalone press).

rightSuper → const KeyType

Right Super/Windows/Command key (standalone press).

rightHyper → const KeyType

Right Hyper key (standalone press).

rightMeta → const KeyType

Right Meta key (standalone press).

isoLevel3Shift → const KeyType

ISO Level 3 Shift (AltGr on some keyboards).

isoLevel5Shift → const KeyType

ISO Level 5 Shift.

unknown → const KeyType

Unknown or unrecognized key.

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<KeyType>
A constant List of the values in this enum, in order of their declaration.