From 2e54123c79a5e83d65550eaa67befd35826a494b Mon Sep 17 00:00:00 2001 From: Kathy Date: Thu, 29 May 2014 13:24:29 +0000 Subject: [PATCH] =?UTF-8?q?commented=20out=20menu=20item=20for=20procedure?= =?UTF-8?q?=E2=80=99s=20removal=20of=20change=20ids=20section=20continue?= =?UTF-8?q?=20message=20no=20longer=20prints=20if=20section/not=20hls=20br?= =?UTF-8?q?eak;=20bottom=20continue=20message=20no=20longer=20prints=20ove?= =?UTF-8?q?r=20bottom=20of=20text=20if=20close=20to=20bottom=20of=20page;?= =?UTF-8?q?=20end=20of=20section=20message=20no=20longer=20prints=20for=20?= =?UTF-8?q?subsections?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- PROMS/Volian.Controls.Library/vlnTreeView.cs | 8 ++++---- PROMS/Volian.Print.Library/vlnParagraph.cs | 12 +++++++++--- 2 files changed, 13 insertions(+), 7 deletions(-) diff --git a/PROMS/Volian.Controls.Library/vlnTreeView.cs b/PROMS/Volian.Controls.Library/vlnTreeView.cs index 9fe3939c..689a37a6 100644 --- a/PROMS/Volian.Controls.Library/vlnTreeView.cs +++ b/PROMS/Volian.Controls.Library/vlnTreeView.cs @@ -626,10 +626,10 @@ namespace Volian.Controls.Library // if this format has change ids that were added from edit, allow removal of // change ids for this procedure: - FolderInfo fi = FolderInfo.Get(1); - FormatInfo frmI = FormatInfo.Get(fi.FormatID ?? 1); - if (frmI.PlantFormat.FormatData.ProcData.ChangeBarData.ChgBarMessageFromEdit) - cm.MenuItems.Add("Remove Change Ids", new EventHandler(mi_Click)); + //FolderInfo fi = FolderInfo.Get(1); + //FormatInfo frmI = FormatInfo.Get(fi.FormatID ?? 1); + //if (frmI.PlantFormat.FormatData.ProcData.ChangeBarData.ChgBarMessageFromEdit) + // cm.MenuItems.Add("Remove Change Ids", new EventHandler(mi_Click)); cm.MenuItems.Add("New Section", new EventHandler(mi_Click)); if (pri.MyDocVersion.MultiUnitCount > 1) { diff --git a/PROMS/Volian.Print.Library/vlnParagraph.cs b/PROMS/Volian.Print.Library/vlnParagraph.cs index 8f44e952..5a4035eb 100644 --- a/PROMS/Volian.Print.Library/vlnParagraph.cs +++ b/PROMS/Volian.Print.Library/vlnParagraph.cs @@ -873,7 +873,7 @@ namespace Volian.Print.Library case 1: // Break on High Level Step OutputOtherPageSteps(cb, YTopMost, yPageStart, yTopMargin, yBottomMargin); docstyle = MyItemInfo.MyDocStyle; - bool doSectionContinue = ((docstyle.StructureStyle.Style & E_DocStructStyle.BottomSectionContinue) == E_DocStructStyle.BottomSectionContinue); + bool doSectionContinue = !MyItemInfo.IsSection && ((docstyle.StructureStyle.Style & E_DocStructStyle.BottomSectionContinue) == E_DocStructStyle.BottomSectionContinue); if (doSectionContinue) DoBottomContinueMsg(cb, yBottomMargin, yLocation, docstyle); cb.PdfDocument.NewPage(); //_MyLog.InfoFormat("NewPage 10 {0}", cb.PdfWriter.CurrentPageNumber); @@ -1064,8 +1064,14 @@ namespace Volian.Print.Library //bool _skipEndMessage = MyPageHelper.MySection.SectionConfig.Section_ColumnMode == SectionConfig.SectionColumnMode.One && !MyItemInfo.ActiveFormat.MyStepSectionLayoutData.EndForSingle; SectionInfo si = MyItemInfo.MyActiveSection as SectionInfo; bool _skipEndMessage = si.SectionConfig.Section_ColumnMode == SectionConfig.SectionColumnMode.One && !MyItemInfo.ActiveFormat.MyStepSectionLayoutData.EndForSingle; + bool _lastSect = true; + if (si.MyActiveParent.IsSection) // is this meta/subsection. Only put end message out on last section + { + ItemInfo mysect = si as ItemInfo; + if (mysect.GetNextItem() != null) _lastSect = false; + } string myMsg = (docstyle.End == null) ? null : docstyle.End.FixedMessage; - if (myMsg != null && !_skipEndMessage) + if (myMsg != null && !_skipEndMessage && _lastSect) { // If the flag is 0 or 1, just put the end message out right below this vlnParagraph: float msg_yLocation = CalculateYLocation(yPageStart - YBottomMost, yTopMargin); @@ -1241,7 +1247,7 @@ namespace Volian.Print.Library case E_ContBottomLoc.BtwnTextAndBottom2: // Like BtwnTextAndBottom but accounts for line spacing of step & is 1 line up on page (for BGE - Procedure Steps - 2 column) float adj = (!MyItemInfo.IsSection && MyItemInfo.FormatStepData.StepLayoutData.EveryNLines == 1) ? SixLinesPerInch : 0; - msg_yLocation = msg_yLocation + yLocation - ((yLocation - yBottomMargin) / 2) + adj + SixLinesPerInch; + msg_yLocation = msg_yLocation + yLocation - ((yLocation - yBottomMargin) / 2) + adj;// +SixLinesPerInch; if (msg_yLocation < yBottomMargin) msg_yLocation = yBottomMargin; break; default: