Wednesday, January 6, 2010

Moving text with a key press

As you might be well aware, there are many ways to move fragments of text within documents. For example, you can use the "cut & paste" method, or if you prefer performing actions with the mouse, "drag & drop".

These methods are fast and easy. They require only a few key presses or mouse clicks. But in some cases you can move text even faster, with only one single key press.

A one-key-press move is possible when you need to move all of the current paragraph, or a selection of paragraphs. Let's take an example.

Let's suppose that you have a list of operating systems in a document. As you can see on the following picture, the name of each Windows version was placed in a separate paragraph (note that a pilcrow symbol terminates each paragraph; pilcrow symbols are visible when you enable the "View | Special Symbols" mode):


Now let's suppose that you want to arrange the names of these Windows systems in chronological order according to their release dates. The current paragraph is "Windows XP", and of course it should be moved up the list.

Let's press the Shift+Alt+Up key combination, and see what happens:


The "Windows XP" paragraph has been moved above the "Windows 7" paragraph.

Now if we press Shift+Alt+Up again, this same "Windows XP" paragraph will appear between the "Windows 2000" and "Windows Vista" paragraphs:


So the Shift+Alt+Up hot key moves the current paragraph up. In other words, it swaps the current and the previous paragraphs. Naturally there is a hot key performing the reverse move: Shift+Alt+Down moves the current paragraph down, ie swaps the current and the next paragraphs.

But that is not all. You can not only move individual paragraphs but also a selection of paragraphs.

Let's get back to the initial order of the Windows versions in our sample list:


Let's select the "Windows Vista" and "Windows 7" paragraphs with the keyboard or mouse:


Pressing the Alt+Shift+Down hot key will move these two paragraphs down and place them after the "Windows XP" paragraph:

No comments: