If you're not using smarttabs, the backslashes will be aligned which is default after TAB or indent-region, but if you use smarttabs, it will become this:
the backslashes will not be aligned after TAB or indent-region, even you set the c-auto-align-backslashes, c-backslash-column and c-backslash-max-column according to GNU Macro-backslashes page, they won't work.
This problem took me hours to find out that it is caused by the smarttabs package. I even posted a question(already deleted after I found the reason) in emacs.stackexchange.com.
If you disable smart-tabs-mode, then use indent-region to fix the backslashes, the right leading tabs and spaces created by smart-tabs-mode seem to still be there. So that's at least a partial workaround.
smarttabs will disable the c-backslashes to align using
TAB
orindent-region
,Say I got a snippet:
If you're not using smarttabs, the backslashes will be aligned which is default after
TAB
orindent-region
, but if you use smarttabs, it will become this:the backslashes will not be aligned after
TAB
orindent-region
, even you set thec-auto-align-backslashes
,c-backslash-column
andc-backslash-max-column
according to GNU Macro-backslashes page, they won't work.This problem took me hours to find out that it is caused by the smarttabs package. I even posted a question(already deleted after I found the reason) in emacs.stackexchange.com.