hi,

On Fri, Aug 01, 2003 at 01:44:41AM +0300, Tuomo Valkonen wrote:
> 
> I haven't tested it, but it might be quite trivial to implement vi-style
> keymaps by adding a 'locked' attribute to submaps causing the grab to
> not be released a key has been pressed. (Esc is hard-coded to kill any
> grab.)

no problem with interrupting the grab, its just what vi does.

the problem was with the two major modes in vi: command mode and
input mode.  in the former most keys are bound to movement function
or to 'operators' which have to be followed by movement key.
quite doable with current ion submaps (well, not a real vi clone
but this is a command line and no editor).
the real problem is, after swiching to input mode all the bindings
have to vanish and the keys have to insert themselves.

so basically one would need two keymaps between which each wedln
can choose individually (or more likely: instanceally).

that having said, the really cool solution would be to use
the readline library and provide it with the custom handlers
to display the line, feed the key strokes, provide the completions and
display them.

ingo

Reply via email to