Skip to content
Snippets Groups Projects
Commit bda854e0 authored by Sam Wilson's avatar Sam Wilson Committed by Marijn Haverbeke
Browse files

[foldcode addon] Add clearOnEnter option

Add option 'clearOnEnter' to foldcode.js and default it to true.
This option determines whether the marker added when folding a
line clears when the cursor enters it.
parent bb91581b
No related branches found
No related tags found
No related merge requests found
......@@ -49,7 +49,7 @@
});
var myRange = cm.markText(range.from, range.to, {
replacedWith: myWidget,
clearOnEnter: true,
clearOnEnter: getOption(cm, options, "clearOnEnter"),
__isFold: true
});
myRange.on("clear", function(from, to) {
......@@ -129,7 +129,8 @@
rangeFinder: CodeMirror.fold.auto,
widget: "\u2194",
minFoldSize: 0,
scanUp: false
scanUp: false,
clearOnEnter: true
};
CodeMirror.defineOption("foldOptions", null);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment