There are thousands and thousands of characters in unicode. There are also lots of symbols and pictographs which can be useful even if you don’t write in a foreign language.
When I create some lists, I very much like to use checkboxes:
✔ setup a blog ✘ configure the blog to be multi-tenant o add content to the blog ☐ todo item ☑ done item ☒ will not do item Because we had ⛈ here, we went by ✈ to some place with lots of ☀ where we wouldn’t need a ☂. So we’re now under a ⛱ ✍ this card to you. |
These special characters usually can not be inserted directly from your keyboard. To add them in your text, press CTRL-vu followed by the four digit hexcode of the unicode character.
- ✔ is hex code 2714
- ✘ is hex code 2718
- ☐ is hex code 2610
- ☑ is hex code 2611
- ☒ is hex code 2612
There are unicode characters which a hex code longer than 4 digits. In my version of vim, I can enter them with CTRL-vU (capital U) followed by the hex code. in this case, the hex code can be as long or as short as it needs to be. To signify the end of the hex code, something must be typed which is not a valid hexadeciman digit (for example <SPACE> or <RETURN>).
If you have a character in a text of which you would like to know the hexcode, this is easy to find out with vim. Place the cursor on the character and in command mode type ga. Vim will show you the character, its decimal, hexadecimal and octal code in the status line.
CTRL-vu <4-digit hex code> | (in insert mode) insert the character with the specified hex code |
CTRL-vU <hex code><non-hex-digit> | (in insert mode) insert the character with the specified hex code (and the non-hex-digit character) |
ga | show the decimal, hexadecimal and octal value of the character under the cursor |