peekKeyPressed

Asynchronously reads Key from STDIN.

version(Posix)
@safe
Key
peekKeyPressed
(
int escDelay = -1
)

Parameters

escDelay int

The escape key detection delay. The default value is -1, this means that the function always waits for two \x1b characters from STDIN.

Return Value

Type: Key

Key structure or Command.empty if STDIN is empty

Meta