Skip to content
Shuai YUAN edited this page May 29, 2015 · 1 revision

Tip 17: Insert Unusual Characters by Character Code

Return to the top: <>

  • Vim can insert any character by its numeric code, and expects the numeric code to consist of three digits: `{code}`
e.g. Insert "A" in insertion mode: `065`
  • Insert a unicode character using its four-digit hexadecimal code: `u{code}`

References:

  • `ga`: show the numeric code for the character on the cursor

References:

| Keystrokes | Effect | | `{123}` | Insert character by decimal code | | `u{1234}` | Insert character by hexadecimal code | | `{nondigit}` | Insert nondigit literally | | `{char1}{char2}` | Insert character represented by `{char1}{char2}` digraph |

Table of Contents


Clone this wiki locally