Skip to content

Instantly share code, notes, and snippets.

@mschulkind
Created May 14, 2011 22:55
Show Gist options
  • Save mschulkind/972728 to your computer and use it in GitHub Desktop.
Save mschulkind/972728 to your computer and use it in GitHub Desktop.
Note that there are some tricks to make special keys work and escape CSI bytes
in the text. The |:map| command also does this, thus you must avoid that it
is done twice. This does not work: >
:imap <expr> <F3> "<Char-0x611B>"
Because the <Char- sequence is escaped for being a |:imap| argument and then
again for using <expr>. This does work: >
:imap <expr> <F3> "\u611B"
Using 0x80 as a single byte before other text does not work, it will be seen
as a special key.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment