+20

Code Folding - Fold All by Syntax/Keyword

Trevor Allen 12 years ago updated 12 years ago 0
Similar to the existing code-folding options "Fold Tag Attributes" and "Fold Level X", it would be great to have an option to fold according to syntax/keyword. For example (in python): Fold All Classes (folds all class definitions); Fold All Function (folds all function definitions); Fold All For-Loops (you get the idea), etc. 

Similarly with HTML, you could fold by tag -- Fold All <tr>, Fold All <table>, etc. 

I don't know whether it would be easy to integrate this with the keyword lists used for syntax highlighting, or perhaps create an area in Preferences files to specify which keywords a user would like included in the Menu or with key-bindings.