I often forget how to insert in visual block mode and read again the answer Shift+i.
As Honghe.Wu wonders in his comment:
Why lowercase i does not work in visual mode?
What is the technical reason?
I often forget how to insert in visual block mode and read again the answer Shift+i.
As Honghe.Wu wonders in his comment:
Why lowercase i does not work in visual mode?
What is the technical reason?
The
i
command inserts before the cursor position. In visual block mode, the cursor position (usually) represents the bottom right corner of the selection, and the cursor position is included in the block.So, the semantics of
i
wouldn't match, and that's why it was left out of the Vim implementation (adding that would probably be a simple one-line change to the source code). The semantics do match forI
(insert before any text) andA
(insert after any text), that's why those are available in visual block mode.The reason because i and a are not behave like in normal mode in all visual modes is that i and a are used to extend the selection to text objects. As you can see in :help visual-operators:
So just use the
block insert
uppercase I or the theblock append
uppercase A commands in visual block mode.