Check out the lastest from Subversion to try out the WIP code folding in RSyntaxTextArea. Simply call:
The fold indicator will be added to the gutter, and fold markers will appear where appropriate. Currently supported languages include:
- C, C++, C#
For other languages, there is no fold parser, so the editor won’t behave any differently than it used to (or shouldn’t!). For the languages above, code blocks and multi-line comments are fold-able. For Java, all import statements are also grouped together into a fold-able region. Folding only currently works when line wrap is disabled – you won’t get any fold indicators if you enable word wrap.
Check it out and give it a go, but please keep in mind that this is an alpha feature! There are likely lots of bugs. Please report ’em either by replying to this post or, even better, by posting them in the forums.
Also, I’m still playing around with the appearance of folded lines. The little icon-ish thing at the end of folded lines (a la NetBeans) is temporary and probably won’t exist in the final version. I’m trying to decide whether coloring the background of folded lines looks better than simply drawing a line across the editor.