IP2 Background: Fixes for bad pagination within Step Description table

This commit is contained in:
Kathy Ruffing 2014-10-08 16:36:50 +00:00
parent 7a25579663
commit 8c806ccd97

View File

@ -243,7 +243,7 @@ namespace Volian.Print.Library
// ResetDocStyleAndValues(ref yTopMargin, ref yBottomMargin);
if (MyPageHelper.DidFirstPageDocStyle && (MyItemInfo.MyActiveSection.MyDocStyle.StructureStyle.Where & E_DocStyleUse.UseOnAllButFirstPage) > 0)
yPageSizeNextPage = GetYPageSizeUseOnAllButFirstPage();
if (KeepStepsOnPage && YSize == ySizeIncludingFirst && YSize + yEndMsg > yWithinMargins)
if (KeepStepsOnPage && !MyItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.StepSectionData.StepSectionLayoutData.PaginateOnLowerStepLevel && YSize == ySizeIncludingFirst && YSize + yEndMsg > yWithinMargins)
{
// If the first step is the size of the entire step and the step has an end message then don't try to break the step
KeepStepsOnPage = false;
@ -541,6 +541,12 @@ namespace Volian.Print.Library
, MyItemInfo.ItemID, MyItemInfo.MyDocVersion.MyFolder.Name, MyItemInfo.ShortPath);
break;
}
if (paraBreak.MyItemInfo.IsStep && ((paraBreak.MyItemInfo.MyActiveSection.MyDocStyle.StructureStyle.Style & E_DocStructStyle.DSS_PageListSpBckgrnd) == E_DocStructStyle.DSS_PageListSpBckgrnd) &&
paraBreak.MyItemInfo.FormatStepData != null && paraBreak.MyItemInfo.MyParent.MyPrevious != null && paraBreak.MyItemInfo.MyParent.MyPrevious.FormatStepData.Type == "TitleWithTextBelow")
{
if (lastBreak != null && lastBreak != paraBreak.MyParent) paraBreak = paraBreak.MyParent;
}
float yLoc = ySpaceOnCurPage - (paraBreak.YOffset - (YTopMost + yTop));
if (yLoc <= 0) // Check where it would break if the space on the page was one line shorter
{