In regular (non-evil) emacs, if you select a rectangular region and hit C-x r t
to run string-rectangle
, inserted text is displayed on all the selected lines as you type.
In Vim, if you select a visual-block and hit I
, inserted text is only displayed on the top line until you finish by hitting Escape
, at which point it inserts the text on all non-empty lines.
I was really hoping that evil-mode would combine the best of both worlds: select a rectangular region, hit I
, and inserted text is displayed on all non-empty lines as you type. Unfortunately, it doesn't display the text as you type.
Is there a way to either make evil-insert
display inserted text on all non-empty lines or get string-rectangle
to respect empty lines?
Edit: I just realized there's also string-insert-rectangle
, which is like visual-block I
, in that it inserts text along the left edge of the rectangle, whereas string-rectangle
is more like visual-block s
because it replaces the existing contents of the rectangle with inserted text.
string-insert-rectangle
also doesn't show the final results in the buffer until you complete your input, which makes me wonder if there's a reason behind this I haven't thought of.