Fix B2015-097: Auto TOC line spacing for empty titles & space character string length for right justified page numbers. Found during internal testing of Auto TOC for South Texas.
This commit is contained in:
parent
cc62e2fd59
commit
0d65f14619
@ -1163,7 +1163,8 @@ namespace Volian.Print.Library
|
||||
|
||||
// adjust ylocation for pagenumber - the ylocation will get reset if the
|
||||
// section title split on 2 lines and the page number needs to be on the 2nd line.
|
||||
if (retval != ttlRetval) yLocation += (retval - ttlRetval);
|
||||
// Only do this if the title is not empty (the code was meant for if title spans more than a line)
|
||||
if (retval != ttlRetval && mySection.MyContent.Text != null && mySection.MyContent.Text != "") yLocation += (retval - ttlRetval);
|
||||
|
||||
// retval = the minimum (further down the page) between section number and
|
||||
// title - this accounts for multi line title.
|
||||
@ -1198,7 +1199,11 @@ namespace Volian.Print.Library
|
||||
}
|
||||
else
|
||||
startSpace = leftMargin + adjSecTitlePos + width + 6;
|
||||
float endSpace = leftMargin + secPagePos - 6;
|
||||
// If the page number is Right justified, need less space characters ('.') so that page number
|
||||
// doesn't have the last space character overwriting the 1st digit:
|
||||
int endJust = (tOfC.TofCPageNumAlign.ToUpper() == "RIGHT") ? 18 : 6;
|
||||
|
||||
float endSpace = leftMargin + secPagePos - endJust;
|
||||
float numSpace = endSpace - startSpace;
|
||||
rtfText = GetRtfToC(tOfC.TofCSpaceChar, tOfC);
|
||||
Paragraph tmpmyparagraph = vlnPrintObject.RtfToParagraph(rtfText);
|
||||
|
Loading…
x
Reference in New Issue
Block a user