This commit is contained in:
parent
24945ac7f2
commit
3a7be58c6e
@ -328,7 +328,8 @@ namespace Volian.Print.Library
|
||||
Console.WriteLine("Not done yet");
|
||||
break;
|
||||
case E_ContBottomLoc.BottomOfPage: // place continue message at bottom of page
|
||||
msg_yLocation = yBottomMargin + 2 * SixLinesPerInch + (float)docstyle.Layout.FooterLength; // 2 lines above bottom margin
|
||||
//msg_yLocation = yBottomMargin + 2 * SixLinesPerInch + (float)docstyle.Layout.FooterLength; // 2 lines above bottom margin
|
||||
msg_yLocation = yBottomMargin + (float)docstyle.Layout.FooterLength;
|
||||
break;
|
||||
default:
|
||||
Console.WriteLine("**** BOTTOM CONTINUE MESSAGE NOT CODED*****");
|
||||
@ -498,7 +499,11 @@ namespace Volian.Print.Library
|
||||
//
|
||||
// If last step & there should be an end message, pagination tests need to account for the 3 lines the end
|
||||
// message uses. The 3 is for a line above, the end message line & the line below (in case there is a border/box line).
|
||||
float yEndMsg = !MyItemInfo.IsSection && MyItemInfo.MyHLS.NextItem == null && (MyItemInfo.MyDocStyle.End.Message ?? "") != "" ? 3 * SixLinesPerInch : 0;
|
||||
|
||||
// The 3 was changed to 2 for the end line & the line below. The blank line below the step gives the blank
|
||||
// line above the end message, thus 2 not 3. This change was made on July 20, 2011 by RHM & KBR. The
|
||||
// procedure in questions was VEWCNEMG\EMGAPP.PRC, ES-01, Step 8.
|
||||
float yEndMsg = !MyItemInfo.IsSection && MyItemInfo.MyHLS.NextItem == null && (MyItemInfo.MyDocStyle.End.Message ?? "") != "" ? 2 * SixLinesPerInch : 0;
|
||||
float yWithinMargins = CalculateYLocation(yLocation, yTopMargin) - yBottomMargin; // -SixLinesPerInch;
|
||||
// if step is breaking over a number of pages, determine if the current step is the
|
||||
// location of a pagebreak.
|
||||
@ -565,14 +570,20 @@ namespace Volian.Print.Library
|
||||
return 0;
|
||||
}
|
||||
// !MyItemInfo.IsHigh - if (MyItemInfo.IsRNOPart && MyParent.XOffset < XOffset) return 0; // Don't paginate on an RNO to the right
|
||||
if (YSize + yEndMsg < yPageSize) // if the entire step can fit on one page, do a page break
|
||||
|
||||
// YSize includes a blank line after the step which we don't want to include in the page break test, thus the
|
||||
// YSize - SixLinesPerInch:
|
||||
if (YSize - SixLinesPerInch + yEndMsg < yPageSize) // if the entire step can fit on one page, do a page break
|
||||
{
|
||||
// Don't want extra line before step
|
||||
//Console.WriteLine("'PageBreak',2,'Yes','HLS will fit on 1 Page',{0},{1},{2}, {3}, {4},'{5}'", MyItemInfo.ItemID, YSize, yPageSize, yWithinMargins, (int)(100 * yWithinMargins / yPageSize), MyItemInfo.ShortPath);
|
||||
ShowPageBreak(5, "HLS will fit on 1 Page at 6 LPI", "Yes", YSize, yPageSize, yWithinMargins);
|
||||
return 1;
|
||||
}
|
||||
// TODO - yEndMsg - compressed size?
|
||||
else if (MyItemInfo.ActiveFormat.MyStepSectionLayoutData.CompressSteps && (ySize7LPI) < (yPageSize * SixLinesPerInch / _SevenLinesPerInch))
|
||||
|
||||
// ySize7LPI includes a blank line after the step which we don't want to include in the page break test.
|
||||
else if (MyItemInfo.ActiveFormat.MyStepSectionLayoutData.CompressSteps && (ySize7LPI - SixLinesPerInch) < (yPageSize * SixLinesPerInch / _SevenLinesPerInch))
|
||||
{
|
||||
//Console.WriteLine("'PageBreak',3,'Yes','HLS will fit on 1 Page at 7 LPI',{0},{1},{2}, {3}, {4},'{5}'", MyItemInfo.ItemID, YSize, yPageSize, yWithinMargins, (int)(100 * yWithinMargins / yPageSize), MyItemInfo.ShortPath);
|
||||
ShowPageBreak(7, "HLS will fit on 1 Page at 7 LPI", "Yes", YSize, yPageSize, yWithinMargins);
|
||||
@ -1106,6 +1117,8 @@ namespace Volian.Print.Library
|
||||
int fixedChgCol = formatInfo.PlantFormat.FormatData.ProcData.ChangeBarData.FixedChangeColumn ?? 0;
|
||||
float cols = formatInfo.MyStepSectionLayoutData.ColS ?? 0;
|
||||
int colr = ToInt(formatInfo.MyStepSectionLayoutData.ColRTable, maxRNO);
|
||||
// if this is a caution or note, put the change bar to the right of the text:
|
||||
if (paragraph.MyItemInfo.IsCaution || paragraph.MyItemInfo.IsNote && fixedChgCol < -10) return -fixedChgCol;
|
||||
if (fixedChgCol < -10 || fixedChgCol >= 0)
|
||||
return ((fixedChgCol > 0) ? fixedChgCol :
|
||||
(fixedChgCol == 0) ? (int)c + 1 :
|
||||
|
Loading…
x
Reference in New Issue
Block a user