Skip to content

Instantly share code, notes, and snippets.

@abitrolly
Created January 31, 2020 15:00
Show Gist options
  • Save abitrolly/7117a23be26c4a76fdf0c185f4bf8d7f to your computer and use it in GitHub Desktop.
Save abitrolly/7117a23be26c4a76fdf0c185f4bf8d7f to your computer and use it in GitHub Desktop.
Error in user YAML: (<unknown>): did not find expected alphabetic or numeric character while scanning an alias at line 1 column 1
---

**Slow by design**

Terminals or "terminal emulators" are slow by design. They use only
two streams - input and output for everything. No parallel key presses
for battle game, no parallel drawing buffers or event queue from
mouse of another controller. Terminals are stateful - you need to wait
for output to switch to specific state before you can draw next symbol
or process next key command. Terminals lose information about key
presses. If you switch Vim to Russian, all key presses in Normal mode
stop to work. Terminals use chars and special sequences of chars to
denote keys like F1 and others. Terminals can't distinguish between
Esc key and other special keys until the next key arrives to the input
or timeout happens. Compared to protocols with direct memory access
and event queues, terminals are an ancient hack which the only main
advantage is ability to interact with any Linux system by just two
wires.

--- 

No terminal is perfect.

Terminator

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment