diff --git a/PROMS/Volian.Base.Library/RtfTools.cs b/PROMS/Volian.Base.Library/RtfTools.cs index d07c1084..4587e0ea 100644 --- a/PROMS/Volian.Base.Library/RtfTools.cs +++ b/PROMS/Volian.Base.Library/RtfTools.cs @@ -138,11 +138,11 @@ namespace Volian.Base.Library // The code below does not look into what font is used, just converts the character. Since any kind of font // can occur during paste, if from an external program, a message will be given stating that a symbol may be incorrect // because an unsupported font was pasted. It was felt that this was sufficient based on estimate of fix versus chance of - // occurrence. + // occurrence. Note that the message was moved into StepRTB since this code is called by non-UI code (5/26/22) if (str.ToUpper().Contains("GREEK") || str.ToUpper().Contains("BALTIC")) { - System.Windows.Forms.MessageBox.Show("Pasted text may use an unsupported font so some characters may not paste correctly and may require delete/reenter of character from within Proms.", - "Paste Font Issue", System.Windows.Forms.MessageBoxButtons.OK); + //System.Windows.Forms.MessageBox.Show("Pasted text may use an unsupported font so some characters may not paste correctly and may require delete/reenter of character from within Proms.", + // "Paste Font Issue", System.Windows.Forms.MessageBoxButtons.OK); for (int i = 0; i < 26; i++) { rtnStr = rtnStr.Replace(string.Format("\\'{0:x2}", 0xc0 + i) // upper case Greek diff --git a/PROMS/Volian.Controls.Library/StepRTB.cs b/PROMS/Volian.Controls.Library/StepRTB.cs index 76f90dd1..41d1591e 100644 --- a/PROMS/Volian.Controls.Library/StepRTB.cs +++ b/PROMS/Volian.Controls.Library/StepRTB.cs @@ -2065,6 +2065,13 @@ namespace Volian.Controls.Library break; } } + // B2022-052: Since any kind of font can occur during paste, if from an external program, a message will + // be given stating that a symbol may be incorrect because an unsupported font was pasted. It was felt + // that this was sufficient based on estimate of fix versus chance of occurrence. Note that the message + // was moved here from rtftools since the rtftools code is called by non-UI code (5/26/22) + if (e.KeyCode==Keys.V && Rtf.ToUpper().Contains("GREEK") || Rtf.ToUpper().Contains("BALTIC")) + System.Windows.Forms.MessageBox.Show("Pasted text may use an unsupported font so some characters may not paste correctly and may require delete/reenter of character from within Proms.", + "Paste Font Issue", System.Windows.Forms.MessageBoxButtons.OK); } if (MyItemInfo == null || MyItemInfo.IsRtfRaw) // B2017-023 null reference check for empty workdraft set information dialog {