Suppose I have the following text.
Foo Bar Foo Foo Bar Bar Bar
Foo Bar Foo Foo Bar Bar Bar
Foo Bar Foo Foo Bar Bar Bar
Foo Bar Foo Foo Bar Bar Bar
Foo Bar Foo Foo Bar Bar Bar
Foo Bar Foo Foo Bar Bar Bar
If I wanted to replace the the first n characters on every line, I would normally perform the following three steps
I, and then type the replacement text.However, there is a faster option when we are operating on one line of text, and that is to use REPLACE mode, which we can get by hitting R in normal mode and then simply typing over the text.
Is there an equivalent REPLACE mode which operates on multiple lines?
The closest thing I could find was to Visual Block select an entire grid of characters, and then hit lowercase r, and type a single character. However, this only works if the replacement text is all the same character, and requires that I know the number of characters I want to replace a priori.
Use c to make a change over a block of text.
Please see:
:h v_b_c
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With