diff --git a/PROMS/Formats/fmtall/MCGall.xml b/PROMS/Formats/fmtall/MCGall.xml index ef5656ab..102f9698 100644 Binary files a/PROMS/Formats/fmtall/MCGall.xml and b/PROMS/Formats/fmtall/MCGall.xml differ diff --git a/PROMS/VEPROMS.CSLA.Library/Format/PlantFormat.cs b/PROMS/VEPROMS.CSLA.Library/Format/PlantFormat.cs index 68c19ca2..31bb2408 100644 --- a/PROMS/VEPROMS.CSLA.Library/Format/PlantFormat.cs +++ b/PROMS/VEPROMS.CSLA.Library/Format/PlantFormat.cs @@ -2681,6 +2681,15 @@ namespace VEPROMS.CSLA.Library return LazyLoad(ref _DontResetIndentOnNewline, "@DontResetIndentOnNewline"); } } + // C2018-024 I in Arial font changed to I in TimesNewRoman + private LazyLoad _ChangeFontUpperCaseIinArial; + public bool ChangeFontUpperCaseIinArial + { + get + { + return LazyLoad(ref _ChangeFontUpperCaseIinArial, "@ChangeFontUpperCaseIinArial"); + } + } } #endregion #region TextTypeValue diff --git a/PROMS/Volian.Print.Library/vlnParagraph.cs b/PROMS/Volian.Print.Library/vlnParagraph.cs index 61fb0286..38402b5d 100644 --- a/PROMS/Volian.Print.Library/vlnParagraph.cs +++ b/PROMS/Volian.Print.Library/vlnParagraph.cs @@ -4556,7 +4556,9 @@ namespace Volian.Print.Library Rtf = FixRTFToPrint(MyItemInfo, Rtf); ProfileTimer.Pop(profileDepth); } - // F2018-013 Changed to static and public so that it can be used with step identifiers for bullets + // C2018-024 I in Arial font changed to I in TimesNewRoman + private static System.Drawing.Font _TNR; + // F2018-013 Changed to static and public so that it can be used with step identifiers for bullets public static string FixRTFToPrint(ItemInfo myItemInfo, string rtf) { // Only do this if the text contains symbols. @@ -4569,6 +4571,31 @@ namespace Volian.Print.Library rtb.Rtf = rtf.Replace(@"\\", ""); // rename backslash character to avoid RTF confusion //string showRTF = rtf; bool changed = false; + // C2018-024 I in Arial font changed to I in TimesNewRoman + if (myItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.StepSectionData.ChangeFontUpperCaseIinArial) + { + bool lastWasNumber = false; + for (int i = 0; i < rtb.TextLength - 1; i++) + { + rtb.Select(i, 2); + if (rtb.SelectionLength == 2) + { + if ((rtb.SelectedText == ".I") && rtb.SelectionFont.FontFamily.Name == "Arial") + { + if (_TNR == null) + _TNR = new System.Drawing.Font("Times New Roman", rtb.SelectionFont.Size, rtb.SelectionFont.Style); + if (lastWasNumber) + { + rtb.SelectionFont = _TNR; + changed = true; + lastWasNumber = false; + } + } + else + lastWasNumber = Regex.IsMatch(rtb.SelectedText, @"[0-9]\."); + } + } + } // C2017-008 - WCN wants the box symbol to look like their checkoff/signoff box // Check for a list of replacement character for symbols in the format file // ReplaceSymbolChars lets you do one or more of the following with a symbol character: diff --git a/PROMS/Volian.Print.Library/vlnTab.cs b/PROMS/Volian.Print.Library/vlnTab.cs index d3b1cd09..893530d6 100644 --- a/PROMS/Volian.Print.Library/vlnTab.cs +++ b/PROMS/Volian.Print.Library/vlnTab.cs @@ -134,6 +134,9 @@ namespace Volian.Print.Library YOffset = yoffset; Text = cleanTab; MyFont = vFont; + // C2018-024 I in Arial font changed to I in TimesNewRoman + if (myparent.MyItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.StepSectionData.ChangeFontUpperCaseIinArial && cleanTab.StartsWith("I.")) + vFont = new VE_Font("Times New Roman", (int)vFont.Size, (E_Style)vFont.Style, (float)vFont.CPI); // BGE has a format flag to increase size of font, if top level: if (doSectTab && myparent.MyItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.SectionNumber.Level0Big && myparent.MyItemInfo.MyParent.IsProcedure) vFont = new VE_Font(vFont.Family, 14, (E_Style)vFont.Style | E_Style.Bold, 8);