This commit is contained in:
Luke Pulverenti 2014-08-24 23:54:53 -04:00
commit 73082a0449
5 changed files with 5 additions and 5 deletions

View File

@ -48,7 +48,7 @@ namespace MediaBrowser.MediaEncoding.Subtitles
}
multiline.Add(line);
}
subEvent.Text = string.Join(@"\N", multiline);
subEvent.Text = string.Join(@"\n", multiline);
subEvent.Text = Regex.Replace(subEvent.Text, @"\{(\\[\w]+\(?([\w\d]+,?)+\)?)+\}", string.Empty, RegexOptions.IgnoreCase);
subEvent.Text = Regex.Replace(subEvent.Text, "<", "&lt;", RegexOptions.IgnoreCase);
subEvent.Text = Regex.Replace(subEvent.Text, ">", "&gt;", RegexOptions.IgnoreCase);

View File

@ -25,7 +25,7 @@ namespace MediaBrowser.MediaEncoding.Subtitles
var text = trackEvent.Text;
// TODO: Not sure how to handle these
text = Regex.Replace(text, @"\\N", " ", RegexOptions.IgnoreCase);
text = Regex.Replace(text, @"\\n", " ", RegexOptions.IgnoreCase);
writer.WriteLine(text);
writer.WriteLine(string.Empty);

View File

@ -147,7 +147,7 @@ namespace MediaBrowser.MediaEncoding.Subtitles
public static string GetFormattedText(string text)
{
text = text.Replace("\\N", Environment.NewLine).Replace("\\n", Environment.NewLine);
text = text.Replace("\\n", Environment.NewLine).Replace("\\n", Environment.NewLine);
bool italic = false;
for (int i = 0; i < 10; i++) // just look ten times...

View File

@ -34,7 +34,7 @@ namespace MediaBrowser.MediaEncoding.Subtitles
{
var text = trackEvent.Text;
text = Regex.Replace(text, @"\\N", "<br/>", RegexOptions.IgnoreCase);
text = Regex.Replace(text, @"\\n", "<br/>", RegexOptions.IgnoreCase);
writer.WriteLine("<p begin=\"{0}\" dur=\"{1}\">{2}</p>",
trackEvent.StartPositionTicks,

View File

@ -23,7 +23,7 @@ namespace MediaBrowser.MediaEncoding.Subtitles
var text = trackEvent.Text;
// TODO: Not sure how to handle these
text = Regex.Replace(text, @"\\N", " ", RegexOptions.IgnoreCase);
text = Regex.Replace(text, @"\\n", " ", RegexOptions.IgnoreCase);
writer.WriteLine(text);
writer.WriteLine(string.Empty);