[IPython-dev] pyreadline: getting callbacks for keypresses from pyreadline
Ville M. Vainio
Thu Jun 14 10:35:38 CDT 2007
Is it possible to register certain keys to certain functions that are
called when that key is pressed? I'm thinking of something like:
def my_translator(line, curpos):
return (line +"appended", curpos)
where my_translator returns the new content for corrent line, along
with cursor position.
This could be used e.g. to launch external editor for current command
line, something that seems to exist in Vi mode. We should rig the
IPython default editor for something like this.
Ville M. Vainio - vivainio.googlepages.com
blog=360.yahoo.com/villevainio - g[mail | talk]='vivainio'
More information about the IPython-dev