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

Is it possible to map a key when you enter r replace character?

Expand Messages
  • Pablo Contreras
    Dear All, I m wondering if there is a mode that allows you to change the character that gets typed when you enter the r character replace mode in normal mode.
    Message 1 of 2 , Jul 26, 2013
    • 0 Attachment
      Dear All,

      I'm wondering if there is a mode that allows you to change the character that gets typed when you enter the r character replace mode in normal mode.

      According to the documentation in map.txt, this says the following:

      ":lmap" defines a mapping that applies to:
      ...
      - the argument of the commands that accept a text character, such as "r" and
      "f"

      sadly for me, the use of :lmap makes no difference to the character gets typed when you enter the argument for the r command or f command as described in the vim help manual.

      I've tried all other mapping modes as well, including :map!, imap, omap, smap, xmap, cmap, vmap, nmap, and all work very well but they do not for r or f command's argument, as it says in the manual.

      Help!!!

      All the best,

      Pablo Contreras.

      --
      --
      You received this message from the "vim_use" 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_use" group.
      To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
      For more options, visit https://groups.google.com/groups/opt_out.
    • John Little
      ... For lmap to work, you need to ... See :help iminsert Surely the help in map.txt should point this out, at least a link to the help for iminsert and
      Message 2 of 2 , Jul 26, 2013
      • 0 Attachment
        On Saturday, July 27, 2013 5:08:47 AM UTC+12, Pablo Contreras wrote:

        > ... for me, the use of :lmap makes no difference

        For lmap to work, you need to

        :set iminsert=1

        See :help 'iminsert

        Surely the help in map.txt should point this out, at least a link to the help for iminsert and imsearch.

        Regards, John Little

        --
        --
        You received this message from the "vim_use" 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_use" group.
        To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+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.