Use extension method to unbreak lines

This commit is contained in:
ivandrofly 2015-06-18 22:23:39 +00:00
parent 58ccd56598
commit 6f398a0428

View File

@ -19,7 +19,7 @@ namespace Nikse.SubtitleEdit.Logic.Forms
return true;
}
var tempText = text.Replace(Environment.NewLine, " ").Replace(" ", " ");
var tempText = Utilities.UnbreakLine(text);
if (Utilities.CountTagInText(tempText, '-') == 2 && (text.StartsWith('-') || text.StartsWith("<i>-")))
{
var idx = tempText.IndexOfAny(new[] { ". -", "! -", "? -" }, StringComparison.Ordinal);