Yesterday I turned my attention back to the vim-bindings project.  The 
absence was beneficial: forgetting coding details helped me see the big 
picture more clearly:

1.  I reviewed the vim cheat sheet to see how I would redesign the bindings 
in the Leo context.  Happily, it looks like the standard vim bindings can 
be used without substantial changes.

- *all* the lowercase command-mode vim bindings seem reasonable.  The 'g' 
and 'Z' commands are catch-alls that could easily be extended to 
accommodate Leo-centric commands.  Otoh, all of Leo's existing commands 
will be available via ':' and Alt-X, so there isn't a big need for trap 
doors, except for vim commands to put the focus in the log, the outline 
pane, etc.

- This morning I realized that the vim keystrokes *themselves* form a kind 
of mini scripting language for the dot command, so commands like [+ (go to 
start of comment) are more useful than they might appear. Otoh, such 
commands can be implemented later, after the basic commands are in place.  
No doubt this is how vim itself developed.

- Similar remarks apply to vim's /find/replace/modifiers syntax.  Although 
I might prefer to use Leo's Ctrl-F based find commands, it might be useful 
to support vim's syntax for use by the dot command.  This can be done later.

2. At last I saw that the best way to discover how vim actually works is to 
type vim key sequences to see what happens.  Doh! Much faster and more 
reliable than reading docs.  I'll be experimenting to discover *exactly* 
how vim handles repeat counts and the dot command.  Imo, it's important to 
duplicate these details exactly.

3. I'm not sure why I thought minibuffer abbreviations were important 
before, but they seem not to be needed for the vim project.

===== Summary

It seems best to stick as closely as possible to vim's existing key 
bindings.  I'll start with the basic (mostly lowercase) vim commands and 
add more commands as needed.

The vim project's key parsing and dispatching mechanism looks like 
overkill, but it works and there is no reason to not have the flexibility 
to define any key bindings anyone could want.

The major task remaining is simply to implement the dot command and the 
other basic commands.  Most commands are very simple, but there will be 
behind-the-scenes complications.  A day or two may suffice to create a 
workable prototype, though we all know how unreliable such initial 
estimates often are.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to