Repeat an expansion

Posted by Emmanuel ® , 05/04/2023, 07:24:05 Reply   Forum

Especially when editing documents there are situations where you may want to repeat the same action several times.

Below you will find an non-exhaustive list of actions you may want to repeat:

  • select next word
  • select previous word
  • lower case next word
  • lower case previous word
  • upper case next word
  • upper case previous word
  • toggle case next word
  • toggle case previous word

Yesterday Marsha asked how to scroll down a document. Scrolling down is an ideal candidate for a repeated action.

The Pick Loop Method that I will introduce in a next post enables you to easily repeat any action. I will show you how it can be applied to scrolling down repeatedly.

Practically, you will start a scroll down loop by expanding a short (here I chose dd):

Upon expanding dd the document will be scrolled down once and the expansion table will display a pick choice that enables you to scroll down again:

At that point, if you want to continue scrolling further down, you will do so by hitting your marker key (or space bar for those who expand with the space bar) in a loop, until you have scrolled down enough.

The expansion table will always propose to scroll again. So you may wonder, how do I stop this loop? Simply by ignoring the displayed pick choice when you are done, and continue typing whatever you want to. The fact that the expansion table displays a pick choice does not mean that you mandatorily need to pick something. :-)

I hope you get the idea, from a pratical point of view.




Edit | Reply | | | |   | Current page | Author