Is there any way to make comments stand out (bold/color)?

Sometimes I really want an important commment to stand out from the rest. Currently, the way I do this is to add @todo in front of the comment, but this is annoying because it's not actually a todo item (I just want the line to stand out).

Is there any kind of markup available that can make text bold and/or change the color, kind of like a todo?



Not really.

But you still can use TODOs for that:

  • just use different marker/"prefix" (instead of "todo", e.g. "NOTE:") -- "Settings | TODO". You can set up different colors just for that.
  • in actual TODOs tool window, you can set up filtering to filter out such fake todos

Alternatively, use different comment type. IDE can have different colors for // (line comment) or /* */ (block comment) and /** */ (PHPDoc block comment)


As of 2022 you can actually add new patterns with cutomize colors in "SETTINGS | Editor > TODO"


I "fixed" this by adding this TODO pattern in settings:

\/\/ [^ ].*

It matches a comment that start with two slashes, exactly 1 space and whatever follows (but no space right after the first one!)

So you can use:

// This is an actual comment that you can give a standing out color
// Comment out code below
//if ($condition) {
// doSomething()

Please sign in to leave a comment.