From c0d12f57214c08f4c7318a87f5d77b44176dbeeb Mon Sep 17 00:00:00 2001 From: Paul Larsen Date: Wed, 25 Mar 2026 11:34:58 -0400 Subject: [PATCH 1/2] B2026-023-Adding-RO-Editor-symbols-to-RO-X_Y_plots --- PROMS/XYPlots/XYPlots.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/PROMS/XYPlots/XYPlots.cs b/PROMS/XYPlots/XYPlots.cs index dc098b3f..7721e5af 100644 --- a/PROMS/XYPlots/XYPlots.cs +++ b/PROMS/XYPlots/XYPlots.cs @@ -491,10 +491,12 @@ namespace XYPlots // remove an extra spaces between >< //Buff = Regex.Replace(Buff, @"[ ]+<", "<"); Buff = Buff.Replace(">\r ", ">\r\n "); + Buff = Buff.Replace(">\n ", ">\r\n "); // C2022-003 if RO has symbols Buff = Regex.Replace(Buff, @"[ ]+<", "<"); // some data only had carriage return, replace these with cr/nl so that following code // will work Buff = Buff.Replace(">\r<", ">\r\n<"); + Buff = Buff.Replace(">\n<", ">\r\n<"); // C2022-003 if RO has symbols Buff = Buff.Replace("><", ">\r\n<"); // some data had cr/cr/nl, change to cr/nl Buff = Buff.Replace("\r\r\n", "\r\n"); @@ -520,6 +522,7 @@ namespace XYPlots Buff = Buff.Substring(0, Buff.Length - 2) + " \r\n\0x00"; // needs to end with null else if (Buff.EndsWith(">")) // doesn't end with return chars... Buff = Buff.Substring(0, Buff.Length - 1) + " \r\n\0x00"; // needs to end with null + Buff = Regex.Replace(Buff, @"\\u([0-9]{1,4})\?", m => int.TryParse(m?.Groups[1]?.Value, out int result) ? Convert.ToChar(result).ToString() : ""); Buff = Regex.Replace(Buff, @"([0-9])\r\n([0-9])", "$1 $2"); } private void CloseGraph() -- 2.49.1 From b7b0e55d9407f835f03fb8257860a1b99d4929b1 Mon Sep 17 00:00:00 2001 From: Paul Larsen Date: Wed, 25 Mar 2026 11:41:39 -0400 Subject: [PATCH 2/2] B2026-023-Adding-RO-Editor-symbols-to-RO-X_Y_plots --- PROMS/XYPlots/XYPlots.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PROMS/XYPlots/XYPlots.cs b/PROMS/XYPlots/XYPlots.cs index 7721e5af..8ac65c0d 100644 --- a/PROMS/XYPlots/XYPlots.cs +++ b/PROMS/XYPlots/XYPlots.cs @@ -522,7 +522,7 @@ namespace XYPlots Buff = Buff.Substring(0, Buff.Length - 2) + " \r\n\0x00"; // needs to end with null else if (Buff.EndsWith(">")) // doesn't end with return chars... Buff = Buff.Substring(0, Buff.Length - 1) + " \r\n\0x00"; // needs to end with null - Buff = Regex.Replace(Buff, @"\\u([0-9]{1,4})\?", m => int.TryParse(m?.Groups[1]?.Value, out int result) ? Convert.ToChar(result).ToString() : ""); + Buff = Regex.Replace(Buff, @"\\u([0-9]{1,4})\?", m => int.TryParse(m?.Groups[1]?.Value, out int result) ? Convert.ToChar(result).ToString() : ""); // C2022-003 RO Symbols. Convert unicode to character. Buff = Regex.Replace(Buff, @"([0-9])\r\n([0-9])", "$1 $2"); } private void CloseGraph() -- 2.49.1