-
Notifications
You must be signed in to change notification settings - Fork 685
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Preprocessor Directive Coloring #2312
Comments
Unfortunately, this is not possible to do with a VS Code extension. Syntax highlighting in VS Code is achieved with regular expressions, which doesn't have the context necessary to perform that level of highlighting. |
The vscode-ccptools has a feature like this (microsoft/vscode-cpptools#1466) maybe this can be adopted for the omnisharp plugin? |
Can't you parse .csproj for |
@DustinCampbell C/C++ extension has this feature, how did they achieve it and can this be done for C#? |
@ssoher If you are using the latest version of the extension, then you can enable the |
@JoeRobich It works great with the included VS themes. But when I add the |
If you maintain your own Theme, you will need to add this line to your theme so that it will use the semantic highlighter. "semanticHighlighting": true, If you are making tweaks to a community theme, you will need to add the same to your |
Amazing, it works now and I've learned something, thank you very much! |
Hello. I am not sure if this is possible(or the right place to ask), but my google skills are failing me :)
I'd like to have preprocessor directives matching the color of comments when they are inactive. Here's what it looks like in visual studio:
![visual_studio](https://user-images.githubusercontent.com/16906875/40125888-0193386e-58fa-11e8-9035-0ea40efc95c4.PNG)
and here's vs code:
![vs_code](https://user-images.githubusercontent.com/16906875/40125905-0807589c-58fa-11e8-903e-c5ba4c84f651.PNG)
The text was updated successfully, but these errors were encountered: