Dear all,
I have been searching this forum for a solution for a while now, but somehow haven’t found a way to achieve what I am looking for. I am on ST4, latest stable release 4143.
I mapped “reindent lines” to by TAB key to have Emacs-style indentation - which works pretty well, but in C++ (and also Python, the main languages I am working with) comment lines are not indented. I would like to change that so comments are also included in the reindent.
I have looked at
-
Can I prevent indentation for toggle comment? but have not succeeded in making this work. The C++ file for
comments.tmPreferences
has a section for the regular//
comment style:<dict> <key>name</key> <string>TM_COMMENT_START</string> <key>value</key> <string>// </string> </dict>
but there is no corresponding
TM_COMMENT_DISABLE_INDENT
setting. So I added it below - with the effect that reindentation goes completely crazy -
Everything you (n)ever wanted to know about indentation in ST3 here I must admit I was completely lost. I am quite happy with the indentation in general and don’t want to tune or change anything - apart from the comment lines…
I hope someone has a pointer for me!
All the best,
herodot