Pagination Logic associated with steps that are too large to fit on a page but the first substep will fit on a page corrected.

Logic added to align the AER step with an RNO step that has a caution or note.
This commit is contained in:
Rich
2014-02-07 15:44:20 +00:00
parent 0f59d980b1
commit 2369fe62dc
2 changed files with 13 additions and 4 deletions

View File

@@ -474,7 +474,8 @@ namespace Volian.Print.Library
float wcnChkLstBorder = myPara.MyItemInfo.MyHLS != null && myPara.MyItemInfo.MyHLS.FormatStepData.UseSmartTemplate &&
(myPara.MyItemInfo.MyHLS.FormatStepData.Suffix ?? "") != "" ? 2*SixLinesPerInch : 0;
if (myPara != lastBreak && (minPara == null || minPara.YTop > myPara.YTop))
minPara = myPara;
if ((-yLocation + yStart) >= yLowerLimit) // Only if it is more than the lower limit
minPara = myPara;
if (myPara.MyParent.YTop == myPara.YTop) myPara = myPara.MyParent;
if (wcnChkLstBorder -yLocation <= yUpperLimit) // Fix for OFN-RJ-23
//if (-yLocation < yUpperLimit) // Before
@@ -486,12 +487,14 @@ namespace Volian.Print.Library
// The top of this step is more than 1/2 way down the page
if ((-yLocation + yStart) >= yLowerLimit)
if (myPara != lastBreak)
return myPara;
if ((-yLocation + yStart) >= yLowerLimit) // Only if it is more than the lower limit
return myPara;
// If this item will not fit on the current page, put a page break
if (myPara.YBottom - myPara.YTop > (yUpperLimit - (-yLocation + yStart)))
if (myPara != lastBreak)
return myPara;
if ((-yLocation + yStart) >= yLowerLimit) // Only if it is more than the lower limit
return myPara;
// if is a caution or note & parent is a substep and entire substep doesn't fit, break.
if ((myPara.MyItemInfo.IsNote || myPara.MyItemInfo.IsCaution) &&
!myPara.MyParent.MyItemInfo.IsHigh &&