neovim/neovim — pull request #914 by equalsraf (2014-07-04 16:13:15+00:00)
Title: [RFC/WIP] Push input via the API

Following from #781 - there is a (currently abort()s) function vim_push_keys() in the API to pass input to Neovim. I enabled the function by calling the old input functions add_to_input_buf() used by the GUI in original Vim.

This is not ideal because it passes bytes directly into the input buffer and what we really want is an API for clients to push input, i.e.:

* key sequences the user types in the keyboard
* key + modifiers e.g. Ctrl+x
* special key + modifiers (by special I mean things that cannot be encoded as strings - F1, Backspace, PgDown)

Finally a quick link to a must read discussion on [vim-dev](http://vim.1045645.n5.nabble.com/Keyboard-input-handling-td1211322.html) on keyboard input. Maybe we can steal some ideas for the API from there.