User forums > Help
[SOLVED]Custom Outlining
jaxxa:
Hi,
sorry if this is the wrong place to post this.
I was wondering if CodeBlocks had a feature Create custom outlining sections.
Somthing similar to VB.NET's #REGION
MortenMacFly:
--- Quote from: jaxxa on March 04, 2009, 04:52:41 am ---Somthing similar to VB.NET's #REGION
--- End quote ---
Do you mean something like:
--- Code: ---//{ WHATEVER COMMENT
...your code...
//}
--- End code ---
...which creates a collapsible region? Sorry if I misunderstood -> I don't know VB.NET's #REGION...?!
jaxxa:
Yes that is what exactly I want.
However i just tried it and it does not seem to be working.
Just how it is with the // it seams to treat it as a comment seems to ignore the { and not create the collapsible box.
Then I remove the // and just have the "{" I get the collapsible box, that is what i want, but the program does not compile
"expected unqualified-id before '{' token"
Am I missing something? In there a setting that I need to change to enable this?
nanyu:
you can get it :
#if 1 //Test for region
//code
#endif
-------------------------
[attachment deleted by admin]
Jenna:
--- Quote from: jaxxa on March 04, 2009, 10:34:50 pm ---However i just tried it and it does not seem to be working.
Just how it is with the // it seams to treat it as a comment seems to ignore the { and not create the collapsible box.
...
Am I missing something? In there a setting that I need to change to enable this?
--- End quote ---
Make sure you have no space between the comment-slashes and the braces.
--- Quote from: nanyu on March 05, 2009, 02:43:51 am ---you can get it :
#if 1 //Test for region
//code
#endif
-------------------------
--- End quote ---
If that does not work out of the box, you have to check "Fold preprocessor commands" in "Settings -> Editor... -> Folding".
Navigation
[0] Message Index
[#] Next page
Go to full version