Thank you for everyone's help so far (reply below)
On Feb 27, 2007, at 12:48 AM, Yakov Lerner wrote:
On 2/26/07, Lev Lvovsky <[EMAIL PROTECTED]> wrote:
I'm sure there's a fancy word for this, but is there any way to pull
text to the right?
suppose I have the following:
COL1 INT,
COL2 INT,
COL3 INT,
I'd like to get "COL3" aligned to "COL1" and "COL2", but to do that,
I need to put the cursor behind "COL3", hit space several times, and
then align "INT" with the other "INTs". Can I put my cursor to the
right of "COL3", and pull it over to "INT" on the right?
Try >> in normal mode. :help >, :help <, :help 'shiftwidth'
That sort of does what I want, but it ends up moving the "INT" right
along with it. I guess what I'm looking for is a combination of key
strokes:
COL1 INT,
COL2 INT,
COL3 INT,
^
I put my cursor at the column of the '^', on line 3 and press that
keystroke, which would simultaneously go to the beginning of the
line, <space>, go back to the '^', and '<x>' from that position, to
bring the "INT" back a space.
The real goal of this formatting is to create text that looks like this:
SOME_COL VARCHAR(32),
SOME_COL12 INT,
BLAH_BLAH1 BOOL,
I would suppose that this can be made with a vim function right? Any
good tutorials on them?
thank you!
-lev