Sublime Forum

Backslashify Code - Plugin

#1

Dear all,

I’m looking for a similar function as Emacs has with its M-x c-backslash-region feature. That function takes a selected region of C code and adds line-continuation backslashes at the end of each line:

#define MACRO(x) \
    { \
        printf(x); \
    }

then becomes:

#define MACRO(x)   \
    {              \
        printf(x); \
    }

with nicely aligned backslashes at the end of each line. One can also type the code with backslashes and Emacs would automatically add and align them.

Is there something similar as plugin or even natively in ST3 and I was just too blind to see it?

Thanks for your help!

Kind regards,
-michael

0 Likes

#2

This popular plugin Alignment is perfect for the job.

0 Likes