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

mappings not working consistently in macros

Expand Messages
  • Jacob Niehus
    I have d mapped to _d and mapped to d . For some reason, this mapping doesn t work reliably in a macro. The problem persists even if I delete my
    Message 1 of 1 , Jan 3, 2014
    • 0 Attachment
      I have 'd' mapped to '"_d' and '<M-d>' mapped to 'd'. For some reason, this mapping doesn't work reliably in a macro. The problem persists even if I delete my .vimrc and all plugins.

      To try out what I'm seeing, :set macmeta, :nnoremap <M-d> d, then put the following text in a buffer:

      foo bar
      foo2 bar2
      foo3 bar3

      Here's a minimal example that works:
      qqw<M-d>wj0q@q

      Here's a tiny change that makes the macro not work ('fb' instead of 'w'):
      qqfb<M-d>wj0q@q

      It puts the cursor on 'bar2' and beeps instead of deleting the word. Any idea what's happening here? I've had to stop using that mapping in macros because it is bizarrely unpredictable.

      One interesting hint is that both macros work fine if I just <M-F1> instead of <M-d>, but <M-Tab> has the same problem as <M-d> despite the fact that <M-Tab> can be mapped without setting macmeta.

      --
      --
      You received this message from the "vim_mac" maillist.
      Do not top-post! Type your reply below the text you are replying to.
      For more information, visit http://www.vim.org/maillist.php

      ---
      You received this message because you are subscribed to the Google Groups "vim_mac" group.
      To unsubscribe from this group and stop receiving emails from it, send an email to vim_mac+unsubscribe@....
      For more options, visit https://groups.google.com/groups/opt_out.
    Your message has been successfully submitted and would be delivered to recipients shortly.