Hi.

It seems that mapping with <char-xxx> does not work.
"char" is being manipulated as modifier keys.

diff -r f33296ed67ea src/misc2.c
--- a/src/misc2.c Wed Aug 17 20:33:23 2011 +0200
+++ b/src/misc2.c Fri Aug 19 17:27:28 2011 +0900
@@ -2793,6 +2793,8 @@
  {
     if (*bp != '-')
     {
+ if (*(bp+1) != '-')
+    break;
  bit = name_to_mod_mask(*bp);
  if (bit == 0x0)
     break; /* Illegal modifier name */
@@ -2800,21 +2802,21 @@
     }
  }
 
+ if (STRNICMP(src + 1, "char-", 5) == 0
+     && VIM_ISDIGIT(src[6]))
+ {
+    /* <Char-123> or <Char-033> or <Char-0x33> */
+    vim_str2nr(src + 6, NULL, NULL, TRUE, TRUE, NULL, &n);
+    *modp = modifiers;
+    *srcp = end_of_name;
+    return (int)n;
+ }
+
  /*
  * Legal modifier name.
  */
  if (bp >= last_dash)
  {
-    if (STRNICMP(last_dash + 1, "char-", 5) == 0
- && VIM_ISDIGIT(last_dash[6]))
-    {
- /* <Char-123> or <Char-033> or <Char-0x33> */
- vim_str2nr(last_dash + 6, NULL, NULL, TRUE, TRUE, NULL, &n);
- *modp = modifiers;
- *srcp = end_of_name;
- return (int)n;
-    }
-
     /*
      * Modifier with single letter, or special key name.
      */

-- 
You received this message from the "vim_dev" 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

Raspunde prin e-mail lui