This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
SyntaxUpdateTokens is working on deprecated syntax support infrastructure (and use TokenID class) => we don't have possibility to support custom code folding if remove our legacy C++ syntax support (see CCKit.initDocument)
In fact, we don't need the exact replacement. As general solution code folding infrastructure could analyze itself all tokens LINE_COMMENT in document and extract needed codefolding tags text (like <editor-fold>/</editor-fold>) Or ask editor kits to do something like: doc.putProperty("folding-tokens", EnumSet.of(CppTokenId.LINE_COMMENT)); then you can use set of dedicated tokens to analyze it's content for folding tags
I'm not sure if I understand it. Since 6.5 CustomFoldManager works with lexer tokens rather then with the old Syntax tokens. It automatically scans all tokens that belong to a primary category called "comment". I don't know off hand what tokens and categories are produced by C++ lexer, but custom code folds should work automagically in any language that creates its comment tokens under the "comment" primary category. Is this the missing piece of information that you needed or did I misunderstand the problem? Thanks
I have checked your statement and all needed is realy already in place (we have "comment" category for comment tokens as well). Great! We had to add syntax based approach in the beginning of 6.5 (or even 6.1), but wasn't aware that it was added in editor in 6.5 later on