I'm currently using SE 22.0.2.1.
I can get the C/C++ Color Coding feature for "Color inactive code regions" to work properly with the preprocessor directive, but only with constant values such as 0 or 1. "#if 0". The Inactive code will properly show as greyed out.
However, I would like to see support for coloring inactive code for the #if <condition>, #ifdef <condition> and #ifndef <condition> directives as well. For this to work, the coloring feature needs to evaluate preprocessor conditions or #defined switch values even if defined in header files.
For instance, I would expect to see the following code greyed out (after the #if directive)
#define USE_HUB_CLASS (0)
.
.
#if USE_HUB_CLASS
<code which should be greyed out here>
#endif
Likewise, I expect the inactive code colorization to work with #ifdef and #ifndef:
#undef ENABLE_FEATURE1
.
.
#ifdef ENABLE_FEATURE1
<this code should be greyed out since switch is not defined>
#endif