From 27c8d89bed5dcb80270b9579093e0ffee0741af8 Mon Sep 17 00:00:00 2001 From: Kathy Date: Thu, 4 Dec 2014 16:03:06 +0000 Subject: [PATCH] =?UTF-8?q?For=20tab=20comparison,=20trim=20strings=20befo?= =?UTF-8?q?re=20doing=20comparison=20in=20code=20that=20determines=20wheth?= =?UTF-8?q?er=20subsection=20number=20is=20derived=20from=20section=20numb?= =?UTF-8?q?er=20(IsSubsectionNumber)=20If=20parent=20was=20continuous=20&?= =?UTF-8?q?=20this=20is=20separate,=20need=20to=20paginate=20to=20get=20su?= =?UTF-8?q?bsection=20on=20its=20own=20page=20For=20sections/subsections:?= =?UTF-8?q?=20if=20parent=20was=20continuous=20&=20this=20is=20separate,?= =?UTF-8?q?=20don=E2=80=99t=20reset=20docstyle=20until=20after=20separate?= =?UTF-8?q?=20section=20pagebreak;=20if=20separator=20location=20is=20?= =?UTF-8?q?=E2=80=980=E2=80=99,=20x-offset=20should=20be=20at=20tab=20not?= =?UTF-8?q?=20text=20of=20step?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs | 4 ++-- PROMS/Volian.Print.Library/Pagination.cs | 4 ++++ PROMS/Volian.Print.Library/vlnParagraph.cs | 17 +++++++++++++++++ 3 files changed, 23 insertions(+), 2 deletions(-) diff --git a/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs b/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs index 1abe4714..5dda8afa 100644 --- a/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs +++ b/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs @@ -1653,8 +1653,8 @@ namespace VEPROMS.CSLA.Library string parNumber = par.DisplayNumber; string myNumber = DisplayNumber; if (parNumber == null || myNumber == null) return false; - if (!parNumber.EndsWith(".0")) return false; - return (myNumber.StartsWith(parNumber.Substring(0, parNumber.Length - 1))); + if (!parNumber.Trim().EndsWith(".0")) return false; + return (myNumber.Trim().StartsWith(parNumber.Trim().Substring(0, parNumber.Length - 1))); } } public bool IsSeparateSubsection diff --git a/PROMS/Volian.Print.Library/Pagination.cs b/PROMS/Volian.Print.Library/Pagination.cs index a43774de..2f51a2d1 100644 --- a/PROMS/Volian.Print.Library/Pagination.cs +++ b/PROMS/Volian.Print.Library/Pagination.cs @@ -35,6 +35,10 @@ namespace Volian.Print.Library if (MyItemInfo.IsSection && MyParent != null && MyParent.MyItemInfo.IsSection && (MyItemInfo as SectionInfo).IsSeparatePagination()) { ShowPageBreak(1, "Page Break between separate sections", "Yes", YSize, yPageSize, yWithinMargins, ManualPageBreak); + + // if parent was continuous & this is separate, need to paginate to get subsection on + // its own page. This occurred in BGE/OI3 set/OI-7 procedure/10.0 Attachments. + if (!(MyParent.MyItemInfo as SectionInfo).IsSeparatePagination()) return 1; if (MyItemInfo.MyPrevious != null) // add if statement to fix Westinghouse print issue 3-21-2014 return 1; } diff --git a/PROMS/Volian.Print.Library/vlnParagraph.cs b/PROMS/Volian.Print.Library/vlnParagraph.cs index 074691f2..8f3994be 100644 --- a/PROMS/Volian.Print.Library/vlnParagraph.cs +++ b/PROMS/Volian.Print.Library/vlnParagraph.cs @@ -1055,8 +1055,13 @@ namespace Volian.Print.Library // at the wrong level. Reset the page helper's section. if (MyItemInfo.IsSection && MyItemInfo.MyPrevious == null && MyItemInfo.MyParent.IsSection && !MyItemInfo.ActiveFormat.PlantFormat.FormatData.PrintData.SpecialCaseWestinghouse) { + // if parent was continuous & this is separate, don't reset document style to subsection (next page) type + // this was putting incorrect pagelist item on parent section's page. This occurred in BGE/OI3 set/OI-7 procedure/10.0 Attachments. + if ((MyParent.MyItemInfo as SectionInfo).IsSeparatePagination() || !(MyItemInfo as SectionInfo).IsSeparatePagination()) + { MyPageHelper.MySection = MyItemInfo as SectionInfo; MyPageHelper.ResetSvg(); + } } // For Calvert Alarms: A macro exists around the CONDITION/RESPONSE portion. If the page break occurs so that @@ -3684,6 +3689,18 @@ namespace Volian.Print.Library } else xoff = XOffset; // XOffset has left margin included + // KEEP: This may be needed in the future to fix location of 'OR's when Separator location="0" + // the following code would place the 'OR' at the location of the tab rather than text. This + // is how 16bit was. However, a number of plants had been sent out with the xoffset at the xlocation + // of text (does not match 16bit) when this was found for BGE OI3/OI-1B/6.1.B.4. Previous releases + // went to CAT, MCG, FPL, NSP. + //{ + // if (this.MyTab != null) + // xoff = this.MyTab.XOffset; + // else + // xoff = XOffset; + //} + vlnHeader myHeader = new vlnHeader(this, cb, itemInfo.MyHeader.Text, itemInfo.MyHeader.CleanText.TrimStart(" ".ToCharArray()), xoff + _MyBoxLeftAdj, YOffset, itemInfo.MyHeader.MyFont); PartsAbove.Add(myHeader); //return myHeader.Height + (!MyItemInfo.MyDocStyle.SpecialStepsFoldout || (MyItemInfo.MyDocStyle.ExtraLineHeader && (MyItemInfo.IsCaution || MyItemInfo.IsNote)) ? SixLinesPerInch : 0);