Comment left align
-
Is there a setting , so that the comment is like
code // codeinstead of
code // code?
-
Sorry, auto-indent keeps comments at the same level of indentation as the code block the comment is a part of (because the auto-indentation is a feature coded at the editor level, whereas the marking of “comment” is coded at the lexer/syntax-highlighter level).
That said, alternatives include:
- running code through an external “pretty print” utility – @Michael-Vincent gives examples of how to do that
in an old post<edit>: in this old post (which was linked from the other; sorry.)</edit> - using one of the scripting plugins (like PythonScript) to set up a hook to watch what you type, and if you type the comment indicator on a line that has only whitespace before that indicator, the script could un-indent for you. Similar things have been done recently, and if you need help, we could dig up links to those previous discussions, and/or someone might be willing to
hack up a scriptengineer a solution for you, if it catches their fancy
- running code through an external “pretty print” utility – @Michael-Vincent gives examples of how to do that
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login