You need to extend the defKeymap prototype. A rationale for prototypes is
explained here:

http://yi-editor.blogspot.se/2008/12/prototypes-encoding-oo-style.html

If it turns out that the piece of code that you need is not accessible in
the prototype, then you can:
 - move the piece of code to the top-level (if it does not depend on other
"things" in the proto.) or
 - move it to the prototype (add a v_... field), if necessary.

Cheers,
JP.

On Fri, Jun 15, 2012 at 6:39 PM, Dmitry Ivanov <etherc...@gmail.com> wrote:

> For example, in vimrc I have this:
> > nnoremap <silent> <Space> :nohlsearch<CR>
> but I can't write something like this:
> > (char ' ' ?>>! ex_mode "nohlsearch\n")
> in yi.hs, because ex_mode function (and pretty much everything related
> to ex commands) is hidden inside a huge where clause of
> Yi.Keymap.Vim.defKeymap.
>
> Another example - I would like to be able to map ';' to ':' to enter
> ex commands without pressing Shift key. I can't figure out a way to do
> that in config file.
>
> Am I missing something?
>
> --
> Yi development mailing list
> yi-devel@googlegroups.com
> http://groups.google.com/group/yi-devel

-- 
Yi development mailing list
yi-devel@googlegroups.com
http://groups.google.com/group/yi-devel

Reply via email to