Loading ...
Sorry, an error occurred while loading the content.

Re: Emacs-like mappings

Expand Messages
  • Yegappan Lakshmanan
    Hi, ... Instead of , you should use : inoremap :echo boink! If you use , after invoking the map, you will be in
    Message 1 of 5 , Oct 2, 2005
    • 0 Attachment
      Hi,

      On 10/2/05, Göran Gustafsson <gustafsson.g@...> wrote:
      > On 10/1/05, Tim Chase <vim@...> wrote:
      > > The following mapping worked for me:
      > >
      > > :inoremap <c-x><c-s> :echo "boink!"<cr>
      > >
      >
      > This actually did work but just to make things clear it should be:
      >
      > :inoremap <c-x><c-s> <esc>:echo "boink!"<cr>
      >

      Instead of "<esc>", you should use <CTRL-O>:

      inoremap <c-x><c-s> <c-o>:echo "boink!"<cr>

      If you use <esc>, after invoking the map, you will be in normal
      mode. If you use <c-o>, after invoking the map, you will still
      be in insert mode.

      - Yegappan

      > :noremap <c-x><c-s> :echo "boink!"<cr>
      >
      > Thanks so much for enlightening me on this subject :-)
      > It's something that i find really useful.
      >
    Your message has been successfully submitted and would be delivered to recipients shortly.