BGE: Fix pagination when a phone list exists

BGE: Auto Table Of Contents, multi-line title leader dots
BGE: Auto ToC, save section title length for printing of leader dots on last line of title
BGE: Fix location of bottom continue message when phone list exists
BGE: Auto ToC, save section title length for printing of leader dots on multi-line of title
This commit is contained in:
2014-05-19 13:16:45 +00:00
parent 5f9331b1b8
commit 86cac2ae13
5 changed files with 54 additions and 22 deletions

View File

@@ -57,9 +57,10 @@ namespace Volian.Print.Library
float yEndMsg = !_skipEndMessage && !MyItemInfo.IsSection && MyItemInfo.MyHLS != null && MyItemInfo.MyHLS.GetNextItem() == null && (MyItemInfo.MyDocStyle.End.Message ?? "") != "" ? 2 * SixLinesPerInch : 0;
// also consider if there is a phone list at the bottom of the page, add the amount of space the phone
// list requires onto yEndMsg to make it easier to figure out pagination.
if (MyItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.PrintPhoneList)
yEndMsg += MyPageHelper.PhoneListHeight;
// list requires onto yEndMsg to make it easier to figure out pagination (include an extra line for the
// horizonal line above the phone list.
if (MyItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.PrintPhoneList && MyPageHelper.PhoneListHeight != 0)
yEndMsg += (MyPageHelper.PhoneListHeight - vlnPrintObject.SixLinesPerInch);
// The following code is to fix a pagination issue in SHE. It was decided to not put it into development
// because some of the pagination logic may be redesigned. Without this fix, some pages had a page break
@@ -419,6 +420,10 @@ namespace Volian.Print.Library
myBottomMsgSpace = 0;
break;
}
// also account for phonelist for locating bottom continue message:
if (MyItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.PrintPhoneList && MyPageHelper.PhoneListHeight != 0)
myBottomMsgSpace += (MyPageHelper.PhoneListHeight - vlnPrintObject.SixLinesPerInch);
string myTopMsg = docstyle.Continue.Top.Message;
float myTopMsgSpace = ((myTopMsg ?? "") != "") ? 2 * SixLinesPerInch : 0;