Mercurial > vim
comparison runtime/doc/eval.txt @ 20627:8bce783af0cb v8.2.0867
patch 8.2.0867: using {xxx} for encoding a modifier is not nice
Commit: https://github.com/vim/vim/commit/fccd93f0917234b962ce07d1df3adf9d7105936f
Author: Bram Moolenaar <Bram@vim.org>
Date: Sun May 31 22:06:51 2020 +0200
patch 8.2.0867: using \{xxx} for encoding a modifier is not nice
Problem: Using \{xxx} for encoding a modifier is not nice.
Solution: Use \<*xxx> instead, since it's the same as \<xxx> but producing a
different code.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sun, 31 May 2020 22:15:03 +0200 |
parents | 8eed1e9389bb |
children | 7b8ac5e49451 |
comparison
equal
deleted
inserted
replaced
20626:38f728a93c07 | 20627:8bce783af0cb |
---|---|
1351 \<xxx> Special key named "xxx". e.g. "\<C-W>" for CTRL-W. This is for use | 1351 \<xxx> Special key named "xxx". e.g. "\<C-W>" for CTRL-W. This is for use |
1352 in mappings, the 0x80 byte is escaped. | 1352 in mappings, the 0x80 byte is escaped. |
1353 To use the double quote character it must be escaped: "<M-\">". | 1353 To use the double quote character it must be escaped: "<M-\">". |
1354 Don't use <Char-xxxx> to get a utf-8 character, use \uxxxx as | 1354 Don't use <Char-xxxx> to get a utf-8 character, use \uxxxx as |
1355 mentioned above. | 1355 mentioned above. |
1356 \{xxx} like \<xxx> but prepends a modifier instead of including it in the | 1356 \<*xxx> Like \<xxx> but prepends a modifier instead of including it in the |
1357 character. E.g. "\<C-w>" is one character 0x17 while "\{C-w}" is four | 1357 character. E.g. "\<C-w>" is one character 0x17 while "\<*C-w>" is four |
1358 bytes: 3 for the CTRL modifier and then character "W". | 1358 bytes: 3 for the CTRL modifier and then character "W". |
1359 | 1359 |
1360 Note that "\xff" is stored as the byte 255, which may be invalid in some | 1360 Note that "\xff" is stored as the byte 255, which may be invalid in some |
1361 encodings. Use "\u00ff" to store character 255 according to the current value | 1361 encodings. Use "\u00ff" to store character 255 according to the current value |
1362 of 'encoding'. | 1362 of 'encoding'. |