Fix forced pagination errors for backgrounds
This commit is contained in:
@@ -1247,11 +1247,8 @@ namespace Volian.Print.Library
|
||||
}
|
||||
if (MyItemInfo.IsHigh && MyItemInfo.MyPrevious != null && ((MyItemInfo.MyDocStyle.StructureStyle.Style & E_DocStructStyle.DoubleBoxHLS) == E_DocStructStyle.DoubleBoxHLS))
|
||||
yPageStart -= SixLinesPerInch;
|
||||
if (MyPageHelper.ParaBreaks.Count > 0 && MyPageHelper.ParaBreaks[0].CompressPreviousPartOfPage)
|
||||
{
|
||||
if (MyPageHelper.ParaBreaks.Count > 0 && MyPageHelper.ParaBreaks[0].CompressFirstPartOfStep)
|
||||
MyPageHelper.YMultiplier = _SevenLinesPerInch / SixLinesPerInch;
|
||||
CompressPartOfPage = false;
|
||||
}
|
||||
if(CompressFoldout)
|
||||
MyPageHelper.YMultiplier = _SevenLinesPerInch / SixLinesPerInch;
|
||||
|
||||
@@ -1323,11 +1320,9 @@ namespace Volian.Print.Library
|
||||
SectionConfig sch = MyItemInfo.ActiveSection.MyConfig as SectionConfig;
|
||||
doSectionTitleContinued = (sch == null || sch.Section_PrintHdr == "Y") && !MyItemInfo.MyDocStyle.CancelSectTitle;
|
||||
}
|
||||
if (MyPageHelper.ParaBreaks.Count > 0 && MyPageHelper.ParaBreaks[0].CompressPreviousPartOfPage)
|
||||
{
|
||||
|
||||
if (MyPageHelper.ParaBreaks.Count > 0 && MyPageHelper.ParaBreaks[0].CompressFirstPartOfStep)
|
||||
MyPageHelper.YMultiplier = _SevenLinesPerInch / SixLinesPerInch;
|
||||
CompressPartOfPage = false;
|
||||
}
|
||||
else
|
||||
MyPageHelper.YMultiplier = 1;
|
||||
break;
|
||||
@@ -1449,10 +1444,10 @@ namespace Volian.Print.Library
|
||||
if (!doSectionTitleContinued || !SectionShowTitles)
|
||||
addExtraLines = DoTopContinueMsg(cb, ref yPageStart, yTopMargin, docstyle, doThreeContinues && MyItemInfo.MyParent != null && MyItemInfo.MyParent.MyTab != null ? MyItemInfo.MyParent.MyTab.CleanText : null);
|
||||
|
||||
if (CompressPartOfPage)
|
||||
if (CompressPartOfStep)
|
||||
{
|
||||
MyPageHelper.YMultiplier = _SevenLinesPerInch / SixLinesPerInch;
|
||||
CompressPartOfPage = false;
|
||||
CompressPartOfStep = false;
|
||||
}
|
||||
else
|
||||
MyPageHelper.YMultiplier = 1;
|
||||
@@ -1621,15 +1616,22 @@ namespace Volian.Print.Library
|
||||
yPageStart = ChildrenLeft.ToPdf(cb, yPageStart, ref yTopMargin, ref yBottomMargin);
|
||||
|
||||
// Handle the PageBreakOnStep flag for a HLS. This will put out the page break right before
|
||||
// a HLS. One example of this use is for backgrounds (CALBCK).
|
||||
// a HLS. One example of this use is for backgrounds (CALBCK).
|
||||
// 'this' below is a highlevel step, and the only time that ParaBreaks[0] will == 'this' is
|
||||
// when the PageBreakOnStep flag is true.
|
||||
if (MyPageHelper.ParaBreaks != null && MyPageHelper.ParaBreaks.Count > 0 &&
|
||||
MyPageHelper.ParaBreaks[0] == this)
|
||||
{
|
||||
if (DebugPagination.IsOpen) DebugPagination.WriteLine("XXXXXXXXXXXXXX Special Page Break (PageBreakOnStep) On Item {0},{1}", MyItemInfo.ItemID, MyItemInfo.ShortPath);
|
||||
ShowPageBreak(1, CheckForCompression("PageBreakOnStep/Caution/Note HLS"), "Yes", YTop - YBottomMost, yTopMargin - yBottomMargin, yTopMargin - yBottomMargin, false);
|
||||
OutputOtherPageSteps(cb, YTopMost, yPageStart, yTopMargin, yBottomMargin);
|
||||
MyPageHelper.BottomMessage = null;
|
||||
MyPageHelper.TopMessage = null;
|
||||
cb.PdfDocument.NewPage();
|
||||
if (CompressPartOfStep)
|
||||
{
|
||||
MyPageHelper.YMultiplier = _SevenLinesPerInch / SixLinesPerInch;
|
||||
CompressPartOfStep = false;
|
||||
}
|
||||
MyPageHelper.ParaBreaks.RemoveAt(0);
|
||||
yPageStart = yTopMargin + YTop;
|
||||
}
|
||||
|
Reference in New Issue
Block a user