Code::Blocks Forums
User forums => Using Code::Blocks => Topic started by: zeroth on January 18, 2013, 06:45:34 pm
-
I've got a defines listed in my project's build options, and an #ifdef for it in a cpp file. the define is true, and the code compiles and executes. however, codeblocks dims the code inside the #ifdef block... and it shouldn't. It's annoying to code in this area because of this.
Is this a bug or was codeblocks just never coded to look for defines there? I'd hack in a quick work-around if I knew what I was looking for... is "code dimming" the proper terminology for this feature?
CodeBlocks svn 8468
-
This depends on the version of C::B you use.
Look into "Settings -> Editor ... -> General settings -> C/C++ editor settings".
-
I presume "Collect defines from the project file" is what you were looking for?
(http://bcaptain.net/settings.png)
-
After unchecking and re-checking that option, the problem is now resolved.
-
I'm using 12.11 release version on Ubuntu 12.04
Works ok with defines in build options and defines in the same source, but fail with defines in headers !!