mirror of
https://github.com/SubtitleEdit/subtitleedit.git
synced 2024-11-26 05:02:36 +01:00
Fixed issue with format "Translation Memory xml" and "&" char - thx ivandrofly :)
This commit is contained in:
parent
b156592432
commit
210bac40b7
@ -73,9 +73,12 @@ namespace Nikse.SubtitleEdit.Core.SubtitleFormats
|
|||||||
string innerXml = paragraphInnerXml;
|
string innerXml = paragraphInnerXml;
|
||||||
innerXml = innerXml.Replace("[START]", p.StartTime.ToString());
|
innerXml = innerXml.Replace("[START]", p.StartTime.ToString());
|
||||||
innerXml = innerXml.Replace("[END]", p.EndTime.ToString());
|
innerXml = innerXml.Replace("[END]", p.EndTime.ToString());
|
||||||
innerXml = innerXml.Replace("[TEXT]", p.Text.Replace(Environment.NewLine, "<br />"));
|
|
||||||
paragraph.InnerXml = innerXml;
|
paragraph.InnerXml = innerXml;
|
||||||
|
|
||||||
|
XmlNode textNode = paragraph.SelectSingleNode("tuv/seg");
|
||||||
|
textNode.InnerText = HtmlUtil.RemoveHtmlTags(p.Text, true);
|
||||||
|
textNode.InnerXml = textNode.InnerXml.Replace(Environment.NewLine, "<br />");
|
||||||
|
|
||||||
body.AppendChild(paragraph);
|
body.AppendChild(paragraph);
|
||||||
count++;
|
count++;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user