Add logic to determine if a section has one high level step and an end message to include the height of the end message when a section will not fit on a page.

When determining the Page Break location in a step, verify that the item before the page break will fit on the page
Add Error Log output if text is low on the page,
This commit is contained in:
2014-09-26 15:39:31 +00:00
parent eac2037172
commit 84f4153900
2 changed files with 20 additions and 1 deletions

View File

@@ -780,6 +780,7 @@ namespace Volian.Print.Library
yPageStart = yTopMargin + YVeryTop;
yLocation = yPageStart - YOffset; // yLocation is physical location from bottom of page.
}
if (yLocation - Height < 24) _MyLog.WarnFormat("Very Low {0},{1},{2},{3},{4},{5}",MyItemInfo.ShortPath,MyItemInfo.ItemID,yLocation,Height,yLocation-Height,yTopMargin - MyItemInfo.MyDocStyle.Layout.PageLength);
retval = Rtf2Pdf.TextAt(cb, IParagraph, XOffset, yLocation, Width, 100, DebugInfo + string.Format(",YLines = {0}",YSize/SixLinesPerInch), yBottomMargin);
if (retval == 0) // problem occurred - paragraph was not able to be printed on page
{ // pagination logic needs to be fixed.