Hi, I'm the author of prompt_toolkit. A library that does something similar for Python. Don't hesitate to copy anything you need. It took me a few iterations to get the API as I wanted.
One thing I underestimated was the importance of having all readline key bindings available. People are really sensitive when certain functionality that they are used to is missing. (And you've no idea how much functionality there is in readline until you have to implement it.)
Thanks jonathan, I'll be sure to take a look. Having feature parity with GNU Readline is something I'm hoping to have in the future, it's a lot of work but it's open source so Im sure I'm not alone :)
One thing I underestimated was the importance of having all readline key bindings available. People are really sensitive when certain functionality that they are used to is missing. (And you've no idea how much functionality there is in readline until you have to implement it.)