More work on new format

This commit is contained in:
Nikolaj Olsson 2020-08-23 16:38:53 +02:00
parent 11c0f317c8
commit 5f00e29509

View File

@ -57,8 +57,10 @@ namespace Nikse.SubtitleEdit.Core.SubtitleFormats
.Replace("Ž", "@")
.Replace("ž", "`")
.Replace("Lj", "Q")
.Replace("LJ", "Q")
.Replace("lj", "q")
.Replace("Nj", "W")
.Replace("NJ", "W")
.Replace("nj", "w")
.Replace("Ć", "]")
.Replace("ć", "}")
@ -144,6 +146,12 @@ namespace Nikse.SubtitleEdit.Core.SubtitleFormats
text = new Regex("ž(\\p{Lu})").Replace(text, "Ž$1");
text = new Regex("(\\p{Lu}\\p{Lu})ž").Replace(text, "$1Ž");
text = new Regex("Q(\\p{Lu})").Replace(text, "LJ$1");
text = new Regex("(\\p{Lu}\\p{Lu})Q").Replace(text, "$1LJ");
text = new Regex("W(\\p{Lu})").Replace(text, "NJ$1");
text = new Regex("(\\p{Lu}\\p{Lu})W").Replace(text, "$1NJ");
var arr = text.TrimEnd('0').Replace("' '", "\n").SplitToLines();
var sb = new StringBuilder();
for (var index = 0; index < arr.Count; index++)