18.6.1.2488.30
XKEY
x-key
XCHAR
 
( -- xchar )

Reads an xchar from the terminal. This will discard all input events up to the completion of the xchar.

See:
Implementation:
: XKEY ( -- xchar )
   KEY DUP $80 U< IF EXIT THEN \ special case ASCII
   $7F AND $40 >R
   BEGIN DUP R@ AND WHILE R@ XOR
     6 LSHIFT R> 5 LSHIFT >R >R KEY
     $3F AND R> OR
   REPEAT R> DROP ;