-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Add a setting to disable inactive region code graying #1574
Comments
We just posted an insider release with the new setting to disable the inactive region colorization. If you want to get an early preview, you can install the VSIX that matches your OS from the link below. https://github.com/Microsoft/vscode-cpptools/releases/tag/v0.16.0-insiders |
Can you also add option to define a list of defines that you want to be define? |
@NiMiZ When you use the "Edit Configurations" command, you should see the "defines" property in "c_cpp_properties.json" where you can add the list of defines. For defines with a value, use a = between the name and value. Let us know if you have a problem getting that to work. |
I'm kinda new in VS Code and I don't know this "Edit Configurations" command bu tI opened the file and I ee the defines property there, but I don't understand how to add a define. Can you give an example? thanks |
Use the View->Command Palette menu and type "Edit Configurations" after the >.
|
I'm using -imacros option to implicitly include c macros to c source files. But cpptools do not appropriatly parse macros when I give header files to "defines" field of c_cpp_properties.json like: |
@unimun, do you want to always pre-include that file? We have a new setting |
@bobbrow Thanks for adding this feature!! It works perfectly. |
I'm a bit late to the party, but I'm seeing really bad editing and scrolling performance on macOS when a big dimmed inactive ifdef region is visible in the editor. It gets slightly better when deactivating the dimming, but it's still slower than normal (maybe it has to do with generally being inside ifdef block). Is this a known issue? It's a bit hard to search for this phenomenon. |
There are some cases where graying the code is undesirable for developers. A setting needs to be added to allow developers to disable the inactive region highlighting.
Consider also adding a lightbulb action to allow developers to toggle this without visiting the settings.json file.
See #1466 for a workaround if you need to disable this immediately. We'll target March (possibly in the insiders release too).
The text was updated successfully, but these errors were encountered: