diff --git a/PROMS/Formats/fmtall/IP3DEVall.xml b/PROMS/Formats/fmtall/IP3DEVall.xml index a0a1b420..230fafbf 100644 Binary files a/PROMS/Formats/fmtall/IP3DEVall.xml and b/PROMS/Formats/fmtall/IP3DEVall.xml differ diff --git a/PROMS/Formats/fmtall/IP3_00all.xml b/PROMS/Formats/fmtall/IP3_00all.xml index 8506f538..2ceed905 100644 Binary files a/PROMS/Formats/fmtall/IP3_00all.xml and b/PROMS/Formats/fmtall/IP3_00all.xml differ diff --git a/PROMS/Formats/fmtall/IP3_02all.xml b/PROMS/Formats/fmtall/IP3_02all.xml index 6db1a53b..8c5b284d 100644 Binary files a/PROMS/Formats/fmtall/IP3_02all.xml and b/PROMS/Formats/fmtall/IP3_02all.xml differ diff --git a/PROMS/Formats/fmtall/IP3_03all.xml b/PROMS/Formats/fmtall/IP3_03all.xml index 5db9728d..32eb1677 100644 Binary files a/PROMS/Formats/fmtall/IP3_03all.xml and b/PROMS/Formats/fmtall/IP3_03all.xml differ diff --git a/PROMS/Formats/fmtall/IP3_06all.xml b/PROMS/Formats/fmtall/IP3_06all.xml index 6479382b..45e8eec2 100644 Binary files a/PROMS/Formats/fmtall/IP3_06all.xml and b/PROMS/Formats/fmtall/IP3_06all.xml differ diff --git a/PROMS/Formats/fmtall/IP3_07all.xml b/PROMS/Formats/fmtall/IP3_07all.xml index e355d3ed..a08cfdaa 100644 Binary files a/PROMS/Formats/fmtall/IP3_07all.xml and b/PROMS/Formats/fmtall/IP3_07all.xml differ diff --git a/PROMS/Formats/fmtall/IP3_08all.xml b/PROMS/Formats/fmtall/IP3_08all.xml index 849863a8..d00c36e5 100644 Binary files a/PROMS/Formats/fmtall/IP3_08all.xml and b/PROMS/Formats/fmtall/IP3_08all.xml differ diff --git a/PROMS/Formats/fmtall/IP3_09all.xml b/PROMS/Formats/fmtall/IP3_09all.xml index 6514b7a4..784f1620 100644 Binary files a/PROMS/Formats/fmtall/IP3_09all.xml and b/PROMS/Formats/fmtall/IP3_09all.xml differ diff --git a/PROMS/Formats/fmtall/IP3_10all.xml b/PROMS/Formats/fmtall/IP3_10all.xml index 6c79c6f2..cfe75bbd 100644 Binary files a/PROMS/Formats/fmtall/IP3_10all.xml and b/PROMS/Formats/fmtall/IP3_10all.xml differ diff --git a/PROMS/Formats/fmtall/IP3_11all.xml b/PROMS/Formats/fmtall/IP3_11all.xml index 3e1fec6d..611cfdbe 100644 Binary files a/PROMS/Formats/fmtall/IP3_11all.xml and b/PROMS/Formats/fmtall/IP3_11all.xml differ diff --git a/PROMS/Formats/fmtall/IP3all.xml b/PROMS/Formats/fmtall/IP3all.xml index aba2ec87..1e834469 100644 Binary files a/PROMS/Formats/fmtall/IP3all.xml and b/PROMS/Formats/fmtall/IP3all.xml differ diff --git a/PROMS/VEPROMS.CSLA.Library/Format/DocStyles.cs b/PROMS/VEPROMS.CSLA.Library/Format/DocStyles.cs index e3a0039b..e6af02c9 100644 --- a/PROMS/VEPROMS.CSLA.Library/Format/DocStyles.cs +++ b/PROMS/VEPROMS.CSLA.Library/Format/DocStyles.cs @@ -771,7 +771,7 @@ namespace VEPROMS.CSLA.Library { get { - return Message == null ? null : Message.Replace("\n","\r\n"); + return Message == null ? null : Message.Replace("\n","\r\n").Replace(@"{par}","\r\n"); } } private LazyLoad _Margin; diff --git a/PROMS/Volian.Print.Library/PromsPrinter.cs b/PROMS/Volian.Print.Library/PromsPrinter.cs index ccb20f02..2dcf5f35 100644 --- a/PROMS/Volian.Print.Library/PromsPrinter.cs +++ b/PROMS/Volian.Print.Library/PromsPrinter.cs @@ -779,7 +779,7 @@ namespace Volian.Print.Library System.Drawing.Drawing2D.Matrix myMatrix = new System.Drawing.Drawing2D.Matrix(0, 1, -1, 0, cb.PdfDocument.PageSize.Height, 0); cb.Transform(myMatrix); } - Rtf2Pdf.TextAt(cb, para, centerpos, ylocation + 6, 100, 12, "", yBottomMargin); + Rtf2Pdf.TextAt(cb, para, centerpos, ylocation + 6, 200, 12, "", yBottomMargin); if (landscape) cb.RestoreState(); } } diff --git a/PROMS/Volian.Print.Library/vlnBox.cs b/PROMS/Volian.Print.Library/vlnBox.cs index 34ad7e00..f4b62fcd 100644 --- a/PROMS/Volian.Print.Library/vlnBox.cs +++ b/PROMS/Volian.Print.Library/vlnBox.cs @@ -415,9 +415,12 @@ namespace Volian.Print.Library // this box is not drawn, it is a series of asterisks drawn above and below text. top = CalculateYOffset(yPageStart, yTopMargin); if (MyPageHelper.YMultiplier != 1) top += 2; - bottom = (yPageStart - (MyParent.YBottomForBox > 0 ? MyParent.YBottomForBox : MyParent.YBottomMost)) * MyPageHelper.YMultiplier; - //_MyLog.WarnFormat("\"ATB\"\t\"{0}\"\t{1}\t{2}\t{3}\t{4}\t{5}\t{6}\t{7}", MyParent, yPageStart, top, bottom, MyPageHelper.YMultiplier, MyPageHelper.CurrentPageNumber, MyParent.YBottomMost, MyParent.YBottomForBox); - + float ytmpbottom1 = yPageStart - (MyParent.YBottomForBox > 0 ? MyParent.YBottomForBox : MyParent.YBottomMost); + if (MyPageHelper.YMultiplier != 1) + { + ytmpbottom1 = (-1 + yTopMargin - (yTopMargin - ytmpbottom1) * MyPageHelper.YMultiplier) + 2; + } + bottom = ytmpbottom1; // create a new font without any styles such as underline. E_Style es = ((vef.Style & E_Style.Bold) == E_Style.Bold) ? E_Style.Bold : E_Style.None; // if the box has a font, use it - otherwise use this item info's font @@ -485,30 +488,44 @@ namespace Volian.Print.Library { // set the top & bottom of sides. If there is a page break in the middle of box, adjust these. // The vlnBox property, ContainsPageBreak, flags that a break occurred. + float yOffBreak = 0; if (!ContainsPageBreak) { top = CalculateYOffset(yPageStart, yTopMargin); if (MyPageHelper.YMultiplier != 1) top += 2; // if this broke, the bottom is defined where the parabreak occurred. - float yOffBreak = MyPageHelper.ParaBreaks.Count > 0 ? MyPageHelper.ParaBreaks[0].YOffset : 0; + yOffBreak = MyPageHelper.ParaBreaks.Count > 0 ? MyPageHelper.ParaBreaks[0].YOffset : 0; if (yOffBreak > 0) bottom = (yPageStart - yOffBreak) * MyPageHelper.YMultiplier; else - bottom = (yPageStart - (MyParent.YBottomForBox > 0 ? MyParent.YBottomForBox : MyParent.YBottomMost)) * MyPageHelper.YMultiplier; + { + float ytmpbottom = yPageStart - (MyParent.YBottomForBox > 0 ? MyParent.YBottomForBox : MyParent.YBottomMost); + if (MyPageHelper.YMultiplier != 1) + { + ytmpbottom = -1 + yTopMargin - (yTopMargin - ytmpbottom) * MyPageHelper.YMultiplier; + } + bottom = ytmpbottom; + } } else { top = CalculateYOffset(yPageStart, yTopMargin); - float yOffBreak = MyPageHelper.ParaBreaks.Count > 0 ? MyPageHelper.ParaBreaks[0].YOffset : 0; + yOffBreak = MyPageHelper.ParaBreaks.Count > 0 ? MyPageHelper.ParaBreaks[0].YOffset : 0; if (yOffBreak > 0) bottom = (yPageStart - yOffBreak) * MyPageHelper.YMultiplier; else - bottom = (yPageStart - (MyParent.YBottomForBox > 0 ? MyParent.YBottomForBox : MyParent.YBottomMost)) * MyPageHelper.YMultiplier; + { + float ytmpbottom1 = yPageStart - (MyParent.YBottomForBox > 0 ? MyParent.YBottomForBox : MyParent.YBottomMost); + if (MyPageHelper.YMultiplier != 1) + { + ytmpbottom1 = -1 + yTopMargin - (yTopMargin - ytmpbottom1) * MyPageHelper.YMultiplier; + } + bottom = ytmpbottom1; + } top = yTopMargin; // reset top to top margin since there was a page break. } // Check that the bottom is within the bottom margin, if this step spans more than one page, // stop the side asterisks at the bottom margin. (pagination puts inserts a page break here) - //_MyLog.WarnFormat("\"AS\"\t\"{0}\"\t{1}\t{2}\t{3}\t{4}\t{5}\t{6}\t{7}", MyParent, yPageStart, top, bottom, MyPageHelper.YMultiplier, MyPageHelper.CurrentPageNumber, MyParent.YBottomMost, MyParent.YBottomForBox); if (bottom < yBottomMargin) bottom = yBottomMargin; float height = (SixLinesPerInch * MyPageHelper.YMultiplier) + 4; // just add a little on so that height is a little bigger than character diff --git a/PROMS/Volian.Print.Library/vlnParagraph.cs b/PROMS/Volian.Print.Library/vlnParagraph.cs index f6aaf3c7..c92ec184 100644 --- a/PROMS/Volian.Print.Library/vlnParagraph.cs +++ b/PROMS/Volian.Print.Library/vlnParagraph.cs @@ -328,6 +328,7 @@ namespace Volian.Print.Library // increment the y offset if not doing the ComponentTableFormat else if (!para.UseTemplateKeepOnCurLine(childItemInfo)) yoff = para.YBottomMost; + // para.YBottomMost += para.YBottomMostAdjust; // KBR for IP3 pagination: don't adjust YBottomost until after yoff is set. if (box != null && childItemInfo.FormatStepData != null && childItemInfo.FormatStepData.BoxIt) { box.Height = yoff - box.YOffset - (1.1F * vlnPrintObject.SixLinesPerInch); @@ -3305,12 +3306,17 @@ namespace Volian.Print.Library MyItemInfo.MyHLS.RNOs != null && MyItemInfo.MyHLS.RNOs.Count > 0) ? 2 * SixLinesPerInch : 0; vlnRNOSeparator myRnoSep = new vlnRNOSeparator(this, cb, tmpRnoSepStr, xsep, yoff+yadjSep, formatInfo, bottomChild == null ? true : bottomChild.MyItemInfo.HasChangeBar); // TODO: May need to handle more than one RNO column for RNO Separator - if (rno.LastRNO.MyItemInfo.HasChangeBar == false && bottomChild != null && bottomChild.MyItemInfo.HasChangeBar) + if ((rno.LastRNO.MyItemInfo.HasChangeBar == false && bottomChild != null && bottomChild.MyItemInfo.HasChangeBar) + || (bottomChild != null && bottomChild.YBottom > rno.LastRNO.YBottomMost)) bottomChild.PartsBelow.Add(myRnoSep); else rno.LastRNO.PartsBelow.Add(myRnoSep); MyHighLevelParagraph.YBottomForBox = 0; - if (yadjSep>0) MyHighLevelParagraph.YBottomForBox = yoff; // if hlrno, box before sep + if (yadjSep > 0) + { + MyHighLevelParagraph.YBottomForBox = yoff; // if hlrno, box before sep + //YBottomMostAdjust = SixLinesPerInch; // KBR for IP3 pagination + } yoff += (myRnoSep.Height + SixLinesPerInch); } YBottomMost = yoff; @@ -4025,6 +4031,12 @@ namespace Volian.Print.Library get { return _YBottomMost; } set { _YBottomMost = value; } } + //protected float _YBottomMostAdjust = 0; // KBR for IP3 pagination + //public float YBottomMostAdjust + //{ + // get { return _YBottomMostAdjust; } + // set { _YBottomMostAdjust = value; } + //} protected float _YTopMost; // Top of the paragraph including the children public float YTopMost {