C# C# Basics (Retired) Prepare and Plan Workspaces

Stefan Kowalski
Stefan Kowalski
117 Points

Color of code

Why my code in workspace does have a different color? For instance "class has blue, program has black, comment has green.

2 Answers

Steven Parker
Steven Parker
177,891 Points

What you are seeing is the result of an editor feature called "syntax highlighting". The editor knows enough about the language to identify certain code elements, and it applies a color to each type to help distinguish them visually.

As you've noticed, keywords are shown in blue, and comments are shown in green. And perhaps you haven't seen it yet, but literal strings are shown in red.

Stefan Kowalski
Stefan Kowalski
117 Points

Thank you for replay. I've formed probably wrong my question because when I've launched my workspce. I have different colors than Jeremy in Video has. In my workspace class is blue in video class is blue, method is blue I video is read.

Steven Parker
Steven Parker
177,891 Points

It's possible that the specific colors changed as part of an editor upgrade that happened since the video was made.