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

cmap not working

Expand Messages
  • reckoner
    Hi, ... Does not trigger completion when I do like it does when I do . What am I missing here? Thanks! -- -- You received this message from the
    Message 1 of 4 , Nov 11, 2013
    • 0 Attachment
      Hi,

      Doing the following:

      :cmap <del> <tab> not working

      Does not trigger completion when I do <del> like it does when I do <tab>.

      What am I missing here?

      Thanks!

      --
      --
      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.
    • Ben Fritz
      ... I guess it s explicitly excluded from mappings: *c_CTRL-I* *c_wildchar* *c_ * wildchar option A match is done on the pattern in front of the cursor.
      Message 2 of 4 , Nov 11, 2013
      • 0 Attachment
        On Monday, November 11, 2013 9:28:47 AM UTC-6, Reckoner wrote:
        > Hi,
        >
        >
        >
        > Doing the following:
        >
        >
        >
        > :cmap <del> <tab> not working
        >
        >
        >
        > Does not trigger completion when I do <del> like it does when I do <tab>.
        >
        >
        >
        > What am I missing here?
        >

        I guess it's explicitly excluded from mappings:

        *c_CTRL-I* *c_wildchar* *c_<Tab>*
        'wildchar' option
        A match is done on the pattern in front of the cursor. The
        match (if there are several, the first match) is inserted
        in place of the pattern. (Note: does not work inside a
        macro, because <Tab> or <Esc> are mostly used as 'wildchar',
        and these have a special meaning in some macros.)

        But Vim does provide 'wildcharm' to allow you to map something to the wildchar. You could set that to <Tab> and your mapping will work. Alternatively, you could set your 'wildchar' option to <Del> and you don't even need the mapping.

        --
        --
        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.
      • Reckoner
        ... Thanks to Ben Fritz for the solution. For completeness,here it is: -- -- You received this message from the vim_use maillist. Do not top-post! Type your
        Message 3 of 4 , Nov 11, 2013
        • 0 Attachment
          On Monday, November 11, 2013 7:28:47 AM UTC-8, Reckoner wrote:
          > Hi,
          >
          >
          >
          > Doing the following:
          >
          >
          >
          > :cmap <del> <tab> not working
          >
          >
          >
          > Does not trigger completion when I do <del> like it does when I do <tab>.
          >
          >
          >
          > What am I missing here?
          >
          >
          >
          > Thanks!

          Thanks to Ben Fritz for the solution. For completeness,here it is:



          --
          --
          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.
        • Reckoner
          ... Thanks to Ben Fritz for the solution. Here it is for completeness: set wildcharm= cmap Works great! -- -- You received this message from
          Message 4 of 4 , Nov 11, 2013
          • 0 Attachment
            On Monday, November 11, 2013 7:28:47 AM UTC-8, Reckoner wrote:
            > Hi,
            >
            >
            >
            > Doing the following:
            >
            >
            >
            > :cmap <del> <tab> not working
            >
            >
            >
            > Does not trigger completion when I do <del> like it does when I do <tab>.
            >
            >
            >
            > What am I missing here?
            >
            >
            >
            > Thanks!

            Thanks to Ben Fritz for the solution. Here it is for completeness:


            set wildcharm=<tab>
            cmap <Del> <tab>

            Works great!

            --
            --
            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.