Index: gc_core/js/text.js ================================================================== --- gc_core/js/text.js +++ gc_core/js/text.js @@ -13,11 +13,11 @@ var text = { getParagraph: function* (sText) { // generator: returns paragraphs of text let iStart = 0; let iEnd = 0; - sText = sText.replace("\r", ""); + sText = sText.replace("\r\n", "\n").replace("\r", "\n"); while ((iEnd = sText.indexOf("\n", iStart)) !== -1) { yield sText.slice(iStart, iEnd); iStart = iEnd + 1; } yield sText.slice(iStart); Index: gc_core/py/text.py ================================================================== --- gc_core/py/text.py +++ gc_core/py/text.py @@ -5,10 +5,11 @@ def getParagraph (sText): "generator: returns paragraphs of text" iStart = 0 + sText = sText.replace("\r\n", "\n").replace("\r", "\n") iEnd = sText.find("\n", iStart) while iEnd != -1: yield sText[iStart:iEnd] iStart = iEnd + 1 iEnd = sText.find("\n", iStart)