diff --git a/PROMS/VEPROMS.CSLA.Library/Format/PlantFormat.cs b/PROMS/VEPROMS.CSLA.Library/Format/PlantFormat.cs index e3a0a9ea..c15dfc36 100644 --- a/PROMS/VEPROMS.CSLA.Library/Format/PlantFormat.cs +++ b/PROMS/VEPROMS.CSLA.Library/Format/PlantFormat.cs @@ -2659,6 +2659,15 @@ namespace VEPROMS.CSLA.Library return LazyLoad(ref _TurnOffReplaceWords, "@TurnOffReplaceWords"); } } + // B2022-002: Section text is printing into the INITIAL column (BNPP1new) + private LazyLoad _AdjWidthForCheckOff; + public bool AdjWidthForCheckOff + { + get + { + return LazyLoad(ref _AdjWidthForCheckOff, "@AdjWidthForCheckOff"); + } + } } #endregion #region SectionNumber diff --git a/PROMS/Volian.Print.Library/vlnParagraph.cs b/PROMS/Volian.Print.Library/vlnParagraph.cs index 3190dee7..4629d79d 100644 --- a/PROMS/Volian.Print.Library/vlnParagraph.cs +++ b/PROMS/Volian.Print.Library/vlnParagraph.cs @@ -6507,6 +6507,15 @@ namespace Volian.Print.Library Width = Width + (float)formatInfo.PlantFormat.FormatData.SectData.SectionHeader.Pos; else if (itemInfo.MyDocStyle.AlignHLSTabWithSect) Width = Width - (float)formatInfo.PlantFormat.FormatData.SectData.SectionHeader.Pos; + + // B2022-002: Section text is printing into the INITIAL column (BNPP1new). If this flag is set adjust the width of the + // section text to that of the first hls (child) text and its tab. This is to prevent the very long section titles (that should have + // been steps) from extending into the INITIAL (checkoff) column. + if (formatInfo.PlantFormat.FormatData.SectData.AdjWidthForCheckOff && MyParent != null && MyParent.MyItemInfo.IsSection && ChkOff && CheckOffWidth != 0 && itemInfo.ItemID == itemInfo.FirstSibling.ItemID) + { + SectionInfo si = MyParent.MyItemInfo.GetSectionInfo(); + if (si.HasInitials) MyParent.Width = Width + ((myTab == null) ? 0 : myTab.Width); + } } else if (bxIndx != null) {