Fixes #1624. Use python3 shebang for all python scripts as python still defaults to python2 on many systems.
Handles basic line-editing with the extended keyboard protocol and support for wide chars. Currently used by the unicode input kitten.