How do I autocomplete macro-defined identifiers from header files while in insert mode?
in insert mode triggers defined identifier completion — it searches for identifiers that match the partial word before the cursor by scanning #define statemen
category:
editing
tags:
#editing
#insert-mode
#completion
How do I autocomplete Vim command names and their arguments while in insert mode?
The key sequence in insert mode triggers Vim command-line completion — the same completion engine used at the : command prompt.
category:
editing
tags:
#insert-mode
#completion
#editing
#command-line
How do I paste from a register in insert mode without Vim interpreting special characters?
In insert mode, {reg} pastes from a register but treats certain bytes as key inputs — so a register containing \n triggers a newline, \x08 triggers backspace,
category:
registers
tags:
#registers
#insert-mode
#editing
#paste
How do I delete the word before the cursor without leaving insert mode?
Pressing in insert mode deletes the word before the cursor instantly, without requiring you to switch to normal mode.
category:
editing
tags:
#editing
#insert-mode
#delete
#productivity
How do I trigger a custom user-defined completion function in insert mode?
Vim's invokes a user-defined completion function, letting you plug any completion logic you want into the standard insert-mode completion popup.
category:
editing
tags:
#completion
#insert-mode
#editing
How do I insert the same text on multiple lines at once?
Visual block mode combined with I lets you insert the same text at the beginning of multiple lines simultaneously.
category:
visual-mode
tags:
#visual-mode
#editing
#insert-mode
How do I insert the result of a Vim expression onto a new line in the buffer?
The :put command inserts the contents of a register as a new line below the cursor.
category:
registers
tags:
#registers
#ex-commands
#editing
How do I include spell-checked words as completion candidates in Vim insert mode?
Adding kspell to the complete option makes and draw from the active spell word list — every word Vim considers correctly spelled.
category:
config
tags:
#completion
#insert-mode
#spell
#config
#editing
How do I break a line at the cursor position without entering Insert mode?
You can split a line at the cursor without entering Insert mode by using r.
category:
editing
tags:
#editing
#normal-mode
#formatting
How do I insert the output of a shell command into my file?
The :r !command command executes a shell command and inserts its output directly into the current buffer below the cursor line.
category:
command-line
tags:
#command-line
#ex-commands
#editing
How do I paste a register's content in Insert mode without Vim adjusting the indentation?
The standard {reg} pastes register contents in Insert mode, but Vim may auto-indent multi-line text to match the current indentation level — sometimes manglin
category:
registers
tags:
#registers
#insert-mode
#editing
How do I insert a literal control character or special key into the command line?
<C-v> (command-line mode)
In command-line mode (after : or /), pressing followed by any key inserts that key literally — bypassing all key notation, mappings, and special interpretatio
category:
command-line
tags:
#command-line
#search
#editing
#insert-mode
How do I insert register contents into the command line?
How it works While typing an Ex command on the command line (after pressing :), you can insert the contents of any register by pressing Ctrl-R followed by the r
category:
registers
tags:
#registers
#ex-commands
#editing
How do I keep concealed text hidden while navigating but automatically reveal it when my cursor enters insert mode?
The 'concealcursor' option controls in which modes concealed text is revealed on the cursor line.
category:
config
tags:
#config
#display
#editing
#concealment
How do I insert a timestamp computed by Vimscript directly from Normal mode?
"=strftime('%Y-%m-%d %H:%M')<CR>p
The expression register lets you evaluate Vimscript on demand and paste the result immediately.
category:
registers
tags:
#registers
#expression-register
#automation
#timestamps
How do I jump back to where I last inserted text and continue typing?
The gi command moves the cursor to the position where you last exited insert mode and immediately enters insert mode again.
category:
navigation
tags:
#navigation
#insert-mode
#marks
#normal-mode
#productivity
How do I insert the filename under the cursor directly into the command line?
While typing a command, inserts the filename under the cursor in the buffer at the command-line prompt.
category:
command-line
tags:
#command-line
#navigation
#editing
How do I paste the current filename into the buffer?
The % register in Vim always contains the name of the current file.
category:
registers
tags:
#registers
#editing
#insert-mode
#productivity
#filename
How do I autocomplete file paths while typing in insert mode?
The command triggers filename completion in insert mode.
category:
editing
tags:
#editing
#insert-mode
#completion
#file-management
#productivity
How do I insert the same text at the start of multiple lines using visual block mode?
Visual block mode () lets you select a rectangular region across lines.
category:
visual-mode
tags:
#visual-mode
#editing
#normal-mode