B2019-103, B2019-114 Paginate on a substep if the step can fit on a blank page and it cannot fit on the current page.
This commit is contained in:
parent
4f2c06df4b
commit
3aa5f48000
@ -1540,6 +1540,11 @@ namespace Volian.Print.Library
|
||||
if (myPara != lastBreak)
|
||||
if ((-yLocation + yStart) >= yLowerLimit) // Only if it is more than the lower limit
|
||||
return myPara;
|
||||
// B2019-103, B2019-114 Break at a step if the step will fit on a page by itself and it will
|
||||
// not fit in the current pagee
|
||||
if (StepWillFitOnBlankPageButNotOnCurrentPage(myPara, yLocation,yStart,fullPage))
|
||||
if (myPara != lastBreak)
|
||||
return myPara;
|
||||
|
||||
// If this item will not fit on the current page, put a page break
|
||||
if (myPara.YBottom - myPara.YTop > (yUpperLimit + yLocation))
|
||||
@ -1570,6 +1575,11 @@ namespace Volian.Print.Library
|
||||
//if(minPara2 != null) DebugPagination.WriteLine("### n222222 {0}", minPara2);
|
||||
return minPara ?? minPara2;
|
||||
}
|
||||
private static bool StepWillFitOnBlankPageButNotOnCurrentPage(vlnParagraph myPara, float yLocation, float yStart,float fullPage)
|
||||
{
|
||||
float spaceOnCurrentPage = fullPage - (-yLocation+yStart);
|
||||
return (myPara.YSize > spaceOnCurrentPage && myPara.YSize < fullPage);
|
||||
}
|
||||
private static bool InSameBox(vlnParagraph myPara, vlnParagraph minPara2)
|
||||
{
|
||||
// see if this paragraph is a note/caution or in a note/caution where its 1st sibling is the input minPara2 (this
|
||||
@ -1639,7 +1649,7 @@ namespace Volian.Print.Library
|
||||
//}
|
||||
public float TableSpaceAvailable// RHM20150525 - Table Scrunch
|
||||
{
|
||||
get // B2019-111 Keep AER Table with parent when RNO extends passt the end of the page.
|
||||
get // B2019-111 Keep AER Table with parent when RNO extends past the end of the page.
|
||||
{
|
||||
float tsa = 0;
|
||||
float tsaRight = 0;
|
||||
@ -1656,8 +1666,6 @@ namespace Volian.Print.Library
|
||||
tsa = pgh.TableSpaceAvailable;
|
||||
vlnParagraph pLast = ChildrenBelow[ChildrenBelow.Count - 1];
|
||||
btm = pLast.YBottomPagination;
|
||||
//if(MyItemInfo.InList(559839))
|
||||
// Console.WriteLine("Here");
|
||||
}
|
||||
if (MyGrid != null)
|
||||
tsa = MyGrid.SpaceAvailable + MyGrid.LeadingSpaceAvailable;
|
||||
|
Loading…
x
Reference in New Issue
Block a user