I don't know if this has been aswered or not, but is it possible to set multiple folding starts and stops in a syntax file? Like can I edit the Java syntax to fold { } *and* /** */?
Jonathan Raphaelson University of Colorado at Boulder --
Home: 303-469-3442 Cell: 720-937-4372
jonathan.raphaelson@colorado.edu jonraphaelson@gmail.com
I don't know if this has been aswered or not, but is it possible to set multiple folding starts and stops in a syntax file? Like can I edit the Java syntax to fold { } *and* /** */?
Not that I know a lot about regular expressions but taking a look in ~/Library/Application Support/TextMate/Bundles/XML.tmbundle/Syntaxes/XML.plist I found:
<key>foldingStartMarker</key> <string>^\s*(<[^!?/]+(?!.+?/>)|(<!--(?!.*?-->))\s*$)</ string> <key>foldingStopMarker</key> <string>(</[^?]+?>|/>|-->)\s*$</string>
Although things are in a different format when looking in /Applications/TextMate.app/Contents/SharedSupport/Bundles/ ActionScript.tmbundle/Syntaxes/ActionScript.plist they're still there:
foldingStartMarker = "(/\*\*|\{\s*$)"; foldingStopMarker = "(\*\*/|^\s*\})";
Which would suggest there's a way to add them as there's pipes in there which I'd imagine act as logical OR's.
Simon