Better compatibility with the Codemirror editor and the markdown circuit extension.

This commit is contained in:
Bridger Maxwell
2012-03-28 14:09:21 -07:00
parent 99b8a51101
commit f95aa496fa
5 changed files with 34 additions and 13 deletions

View File

@@ -980,7 +980,7 @@ var CodeMirror = (function() {
maxWidth = scroller.clientWidth;
var curNode = lineDiv.firstChild, heightChanged = false;
doc.iter(showingFrom, showingTo, function(line) {
if (!line.hidden && !line.widgetFunction) { //TODO: We should handle widget blocks better here
if (!line.hidden && !line.widgetFunction) {
var height = Math.round(curNode.offsetHeight / th) || 1;
if (line.widgetFunction) height = line.widgetFunction.size(line.text).height / textHeight();
if (line.height != height) {