B2017-139: SAMG Facing page print has missing blank pages
This commit is contained in:
parent
24d6cf60ab
commit
61af3b60cc
@ -891,10 +891,10 @@ namespace Volian.Print.Library
|
|||||||
_MyHelper.OnBlankPage = true;
|
_MyHelper.OnBlankPage = true;
|
||||||
cb.PdfDocument.Add(new iTextSharp.text.Table(1));
|
cb.PdfDocument.Add(new iTextSharp.text.Table(1));
|
||||||
NewPage();
|
NewPage();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
firstStepSec = false;
|
firstStepSec = false;
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
CreateStepPdf(mySection, cb);
|
CreateStepPdf(mySection, cb);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -1604,10 +1604,13 @@ namespace Volian.Print.Library
|
|||||||
yPageStart = _yPageStartForSupInfo - SixLinesPerInch;
|
yPageStart = _yPageStartForSupInfo - SixLinesPerInch;
|
||||||
yLocation = yPageStart - YTopMost;
|
yLocation = yPageStart - YTopMost;
|
||||||
}
|
}
|
||||||
|
if (MyPromsPrinter.SupInfoPrintType == E_SupInfoPrintType.Merge)
|
||||||
|
{
|
||||||
// printing a procedure with section(s) that have supplemental information - determine facing page needed to be merged in. For
|
// printing a procedure with section(s) that have supplemental information - determine facing page needed to be merged in. For
|
||||||
// case 0, it is typically at the beginning of the section since the page break occurred in the code that calls this.
|
// case 0, it is typically at the beginning of the section since the page break occurred in the code that calls this.
|
||||||
// Note that if the procedure has any sections with supinfo, then the entire procedure will need facing pages, either blank page
|
// Note that if the procedure has any sections with supinfo, then the entire procedure will need facing pages, either blank page
|
||||||
// or supinfo steps. Also, if the section title is printed, then need to get the facing page before the section title is printed and if
|
// or supinfo steps.
|
||||||
|
// If the section title is printed, then need to get the facing page before the section title is printed and if
|
||||||
// this is the hls where the section title was printed, don't do the facing page.
|
// this is the hls where the section title was printed, don't do the facing page.
|
||||||
bool titlePrinted = false;
|
bool titlePrinted = false;
|
||||||
if (MyItemInfo.IsSection || (MyItemInfo.IsHigh && MyItemInfo.MyPrevious == null))
|
if (MyItemInfo.IsSection || (MyItemInfo.IsHigh && MyItemInfo.MyPrevious == null))
|
||||||
@ -1617,7 +1620,21 @@ namespace Volian.Print.Library
|
|||||||
titlePrinted = (sch == null || sch.Section_PrintHdr == "Y") || !(MyItemInfo.MyActiveSection as SectionInfo).HasSupInfoSteps;
|
titlePrinted = (sch == null || sch.Section_PrintHdr == "Y") || !(MyItemInfo.MyActiveSection as SectionInfo).HasSupInfoSteps;
|
||||||
titlePrinted &= (ShowSectionTitles && !MyItemInfo.MyDocStyle.CancelSectTitle);
|
titlePrinted &= (ShowSectionTitles && !MyItemInfo.MyDocStyle.CancelSectTitle);
|
||||||
}
|
}
|
||||||
if (MyPromsPrinter.SupInfoPrintType == E_SupInfoPrintType.Merge && (MyItemInfo.ActiveSection as SectionInfo).HasSupInfoSteps && ((MyItemInfo.IsHigh && MyItemInfo.MyPrevious == null && !titlePrinted) || (MyItemInfo.IsStepSection && titlePrinted)) && !MyItemInfo.IsInSupInfo && (MyItemInfo.MyProcedure as ProcedureInfo).ProcHasSupInfoData)
|
// If this is first step section and there is no supinfo, the blank page was done in proms printer.
|
||||||
|
// If this is first step section and there is supinfo, it needs to be put out
|
||||||
|
bool notFirstOrFirstHasSupInfo = false;
|
||||||
|
bool firstSec = true;
|
||||||
|
foreach (SectionInfo sec in MyItemInfo.MyProcedure.Sections)
|
||||||
|
{
|
||||||
|
if (sec.IsStepSection)
|
||||||
|
{
|
||||||
|
if (sec.ItemID == MyItemInfo.MyActiveSection.ItemID) break;
|
||||||
|
firstSec = false;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
notFirstOrFirstHasSupInfo = !firstSec || (MyItemInfo.ActiveSection as SectionInfo).HasSupInfoSteps;
|
||||||
|
if (notFirstOrFirstHasSupInfo && ((MyItemInfo.IsHigh && MyItemInfo.MyPrevious == null && !titlePrinted) || (MyItemInfo.IsStepSection && titlePrinted)) && !MyItemInfo.IsInSupInfo && (MyItemInfo.MyProcedure as ProcedureInfo).ProcHasSupInfoData)
|
||||||
{
|
{
|
||||||
// If there is supplemental information to be printed on the facing page, then get the id that has supinfo
|
// If there is supplemental information to be printed on the facing page, then get the id that has supinfo
|
||||||
// so that it can be retrieved from the pdf for the supinfos for this section.
|
// so that it can be retrieved from the pdf for the supinfos for this section.
|
||||||
@ -1633,6 +1650,7 @@ namespace Volian.Print.Library
|
|||||||
MyPromsPrinter.NewPage();
|
MyPromsPrinter.NewPage();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
if (MyItemInfo.IsHigh && MyItemInfo.MyPrevious != null && ((MyItemInfo.MyDocStyle.StructureStyle.Style & E_DocStructStyle.DoubleBoxHLS) == E_DocStructStyle.DoubleBoxHLS))
|
if (MyItemInfo.IsHigh && MyItemInfo.MyPrevious != null && ((MyItemInfo.MyDocStyle.StructureStyle.Style & E_DocStructStyle.DoubleBoxHLS) == E_DocStructStyle.DoubleBoxHLS))
|
||||||
yPageStart -= SixLinesPerInch;
|
yPageStart -= SixLinesPerInch;
|
||||||
if (MyPageHelper.ParaBreaks.Count > 0 && MyPageHelper.ParaBreaks[0].CompressFirstPartOfStep)
|
if (MyPageHelper.ParaBreaks.Count > 0 && MyPageHelper.ParaBreaks[0].CompressFirstPartOfStep)
|
||||||
@ -1815,7 +1833,7 @@ namespace Volian.Print.Library
|
|||||||
MyPromsPrinter.NewPage();
|
MyPromsPrinter.NewPage();
|
||||||
_MyLog.InfoFormat("NewPage Break within step blank {0}", cb.PdfWriter.CurrentPageNumber);
|
_MyLog.InfoFormat("NewPage Break within step blank {0}", cb.PdfWriter.CurrentPageNumber);
|
||||||
}
|
}
|
||||||
if (!MyPageHelper.CreatingSupInfoPage && !MyItemInfo.IsSection && !MyItemInfo.IsInSupInfo && (MyItemInfo.MyProcedure as ProcedureInfo).ProcHasSupInfoData)
|
if (MyPromsPrinter.SupInfoPrintType == E_SupInfoPrintType.Merge && !MyPageHelper.CreatingSupInfoPage && !MyItemInfo.IsSection && !MyItemInfo.IsInSupInfo && (MyItemInfo.MyProcedure as ProcedureInfo).ProcHasSupInfoData)
|
||||||
{
|
{
|
||||||
int sid = GetIdThatHasSupInfoItems(MyItemInfo, MyItemInfo.ItemID);
|
int sid = GetIdThatHasSupInfoItems(MyItemInfo, MyItemInfo.ItemID);
|
||||||
if (sid != -1)
|
if (sid != -1)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user