1. I have been trying to figure out a command that would let me place
parenthesis (()) around a word, line paragraph or whatever. I.e.  

g(w    could put parens around a word
g($    could put parens around cursor position and end of line, likewise
g(^    could do beginning of line and cursor
g("    around a quoted string
g(ap   around a paragraph, etc.  

I'm sure you get my point.  I tried to write a function visualmode()
parameter but I just can't seem to get all my situations. Ideally,
g({motion} would parenthesis whatever I specify in {motion}.

2. I often times like to line up certain characters to match characters
on the line above or below.  I.e:

void SomeLongFunctionName( void );
void SomeFunc( void );

I would like to put my cursor on the ( on the 2nd line and type
something like "\at("  for "align to (" (on the line above would be
implied, but perhaps "\aT(" would be line below? )

This I haven't attempted yet but my only idea would be to make a
function that calls getpos("."), subtract 1 from line, read the line,
count up to the next ( and do a for insert-loop.  Is there a better way?

Any help is much appreciated!
Chuck



Reply via email to