B2018-024: Pagination of Supplemental Information

This commit is contained in:
Kathy Ruffing 2018-02-16 13:20:12 +00:00
parent cd9bb3984c
commit faeb407c59

View File

@ -906,6 +906,7 @@ namespace Volian.Print.Library
// to have page breaks. As each of these are processed (after this code) the topmost item in PageBreakOnStepList is removed.
// The following checks if the entire step will fit for these types of steps and if so return the next break, i.e. [0], from the PageBreakOnStepList.
// The if was changed to fix B2017-161.
bool DidPreferredPageBreak = false;
if (PageBreakOnStepList.Count > 0 && (PageBreakOnStepList[0].YTop - (lastBreak == null ? ((TopMostChild != null) ? TopMostChild.YTop : 0) : lastBreak.YTop) <= ySpaceOnCurPage))
paraBreak = PageBreakOnStepList[0];
else
@ -921,6 +922,7 @@ namespace Volian.Print.Library
if (lastBreak == null || lastBreak.MyItemInfo.ShortPath.CompareTo(prefBreak.MyItemInfo.ShortPath) == -1)
paraBreak = prefBreak;
myPreferredBreaks.RemoveAt(0);
DidPreferredPageBreak = true;
}
}
// B2017-252 Pagination Fix - Break at title rather than title content
@ -1123,7 +1125,8 @@ namespace Volian.Print.Library
// This fixes B2016-174:
// Added the check to not go into this code if on a step that needs to break. If the conditions were met, this
// code was not putting a page break on a step that needed to break, i.e. PageBreakOnStep = true.
if ((MyItemInfo.IsStep && !MyItemInfo.FormatStepData.PageBreakOnStep) && MyItemInfo.ActiveFormat.MyStepSectionLayoutData.PartialStepCompression && onNewPage) // ySpaceOnNextPage1 == ySpaceOnCurPage+myBottomMsgSpace)
// B2018-024: Added the 'DidPreferredPageBreak', don't do the compressed code if a preferred page break exists on the step.
if (!DidPreferredPageBreak && (MyItemInfo.IsStep && !MyItemInfo.FormatStepData.PageBreakOnStep) && MyItemInfo.ActiveFormat.MyStepSectionLayoutData.PartialStepCompression && onNewPage) // ySpaceOnNextPage1 == ySpaceOnCurPage+myBottomMsgSpace)
{
float ySpaceAt7LPI = ((ySpaceOnCurPage - accountForCalvertAlarmConditionResponseFooter) * SixLinesPerInch / _SevenLinesPerInch) - _SevenLinesPerInch;
vlnParagraph paraBreak7 = FindPageBreak(yStart, ySpaceAt7LPI, yLowerLimit,