2

Anyone know of a simple way of adding syntax highlighting rules to the default syntax coloring in the eclipse java jdt? I would like to show constants of various kinds in a specific colour.

Such as: final members and enum value literals (not the enum type name). Numbers and strings are already supported, as is static final member.

1 Answer 1

0

Preferences -> JAVA -> Editor -> Syntax Coloring

And in Element box select static final fields under java you can change your color by what you want for your constant

Sign up to request clarification or add additional context in comments.

1 Comment

Yep, thanks. Numbers, strings, and static final are supported, but non static final is not, nor enum value literals. Good that I can get some the way I prefer, but it would be great to have a way to get the rest as well. I'm trying to find a way to deal with the rest of the "constant"-ish variants.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.