(doc, from, to)
| 1004 | } |
| 1005 | // Get the lines between from and to, as array of strings. |
| 1006 | function getLines(doc, from, to) { |
| 1007 | var out = [] |
| 1008 | doc.iter(from, to, function (line) { |
| 1009 | out.push(line.text) |
| 1010 | }) // iter aborts when callback returns truthy value |
| 1011 | return out |
| 1012 | } |
| 1013 | |
| 1014 | // Update the height of a line, propagating the height change |
| 1015 | // upwards to parent nodes. |