AlignTab icon indicating copy to clipboard operation
AlignTab copied to clipboard

Align text by end of pattern.

Open AndrewAndreev opened this issue 10 years ago • 4 comments

Hello. It's very cool and powerful package. But I can't figure out how to align this code:

int a;
char *b;
char **c;

By this way:

int    a;
char  *b;
char **c;

In ordinary case it will match in \**\w; regexp, but it will form this code:

int  a;
char *b;
char **c;

So, is it possible? If it is not I would suggest this as feature requiest. Option to align text by end of patterns instead of start.

AndrewAndreev avatar May 04 '16 07:05 AndrewAndreev

\**\w/lr0 should work.

randy3k avatar May 04 '16 07:05 randy3k

@randy3k definitely it works, thanks! But what is /lr ? Is there any documentation on this kind of regexp?

AndrewAndreev avatar May 05 '16 06:05 AndrewAndreev

Check this part of the documentation.

randy3k avatar May 05 '16 06:05 randy3k

I've got it, thanks!

AndrewAndreev avatar May 05 '16 07:05 AndrewAndreev