MCPcopy
hub / github.com/nwutils/nw-sample-apps / setValue

Function setValue

mini-code-edit/cm/lib/codemirror.js:341–346  ·  view source on GitHub ↗
(code)

Source from the content-addressed store, hash-verified

339 }
340
341 function setValue(code) {
342 var top = {line: 0, ch: 0};
343 updateLines(top, {line: doc.size - 1, ch: getLine(doc.size-1).text.length},
344 splitLines(code), top, top);
345 updateInput = true;
346 }
347 function getValue() {
348 var text = [];
349 doc.iter(0, doc.size, function(line) { text.push(line.text); });

Callers 1

CodeMirrorFunction · 0.85

Calls 2

updateLinesFunction · 0.85
getLineFunction · 0.85

Tested by

no test coverage detected