add fold detection rules for python and c style languages

This commit is contained in:
nightwing 2011-11-28 18:09:39 +04:00
commit 4677db58d8
9 changed files with 250 additions and 51 deletions

View file

@ -52,6 +52,11 @@ oop.inherits(Mode, TextMode);
(function() {
this.foldingRules = {
foldingStartMarker: /\:(:?\s*)?(:?#.*)?$/,
getFoldWidgetRange: "indentationBlock"
};
this.toggleCommentLines = function(state, doc, startRow, endRow) {
var outdent = true;
var outentedRows = [];