Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Change color of Eclipse todo only - not whole comment

I found out how to change the color of the todo tag in eclipse (window->preferences->general->editors->text editors->annotations->tasks) but this changes it so that when I write //TODO the entire line is affected. Is it possible so make it so that ONLY the word TODO is afected?

like image 317
David says Reinstate Monica Avatar asked Dec 02 '12 18:12

David says Reinstate Monica


People also ask

How do I create a TODO comment in eclipse?

ctrl-shift-F9 was just a random example, to make you realize that any shortcut would ba as long to type as // TODO.

What is the purpose of adding todo in a comment in eclipse?

Programmers like to place TODO markers in their code which serves as a reminder for tasks that need to be completed. Comments in the Java code that has the word TODO in them are recognized as task and shown on the marker bar and in the Tasks view.


1 Answers

Is it possible so make it so that ONLY the word TODO is afected?

Yes, you can change the color of "task tag" comments under Preferences → Java → Editor → Syntax Coloring ⇉ Comments → Task Tags, as shown in the screenshot below. Note that "TASK" in the preview window is hot pink. "TODO" is a task tag, so it also appears hot pink for me.

Imgur

like image 187
user1201210 Avatar answered Sep 24 '22 21:09

user1201210