Added gap in centerline for grid for processing VCSummer data
Changed how page length was determined when deciding how to paginate a procedure for processing VCSummer data Utilized FixedMessage property for processing VCSummer data Utilized DocStyle.LandscapePageList property for processing VCSummer data Added gap in centerline for boxes for processing VCSummer data Changed ToPdf method to pass yTopMargin and yBottomMargin by reference Chnaged calls to ToPdf method to pass yTopMargin and yBottomMargin by reference Changed how vlnParagraph was processed with regards to Notes and Caution boxes to support nuances in VCSummer data Added code to support macro substitutions in continue messages and end of procedure messages for processing VCSummer data Added drawing centerline and handling gaps in centerline for processing VCSummer data Added RomanNumbering of pages for processing VCSummer data Added classes Gap and Gaps for processing VCSummer data Utilized MacroTabAdjust property for processing VCSummer data Changed how vlnText width was calculated for processing VCSummer data
This commit is contained in:
@@ -114,11 +114,51 @@ namespace Volian.Print.Library
|
||||
}
|
||||
if (MySection.MyDocStyle.StructureStyle.Style==null || (MySection.MyDocStyle.StructureStyle.Style & E_DocStructStyle.DontCountInTabOfCont) == 0)
|
||||
CurrentTOCPageNumber++;
|
||||
if (MySection.MyDocStyle.CenterLineX != null && MySection.ColumnMode > 0)
|
||||
DrawCenterLine(writer.DirectContent, MySection.MyDocStyle.Layout.LeftMargin + MySection.MyDocStyle.CenterLineX ?? 0, MySection.MyDocStyle.CenterLineYTop ?? 0, MySection.MyDocStyle.CenterLineYBottom ?? 0);
|
||||
PageListTopCheckOffHeader = null;
|
||||
PageListLastCheckOffHeader = null;
|
||||
YMultiplier = 1;
|
||||
|
||||
}
|
||||
private Gaps _MyGaps;
|
||||
public Gaps MyGaps
|
||||
{
|
||||
get
|
||||
{
|
||||
if (_MyGaps == null)
|
||||
_MyGaps = new Gaps();
|
||||
return _MyGaps;
|
||||
}
|
||||
}
|
||||
public void AddGap(float top, float bottom, float left, float right)
|
||||
{
|
||||
float center = MySection.MyDocStyle.Layout.LeftMargin + MySection.MyDocStyle.CenterLineX ?? 0;
|
||||
if(center == 0) return;
|
||||
if (center > right || center < left) return;
|
||||
MyGaps.Add(top, bottom);
|
||||
}
|
||||
private void DrawCenterLine(PdfContentByte cb, float xLoc, float yTop, float yBottom)
|
||||
{
|
||||
cb.SaveState();
|
||||
if (PageListLayer != null) cb.BeginLayer(PageListLayer);
|
||||
cb.SetLineWidth(.95f);
|
||||
cb.SetColorStroke(new Color(PrintOverride.SvgColor));
|
||||
cb.MoveTo(xLoc, yTop);
|
||||
if (_MyGaps != null)
|
||||
{
|
||||
foreach (Gap gap in MyGaps)
|
||||
{
|
||||
cb.LineTo(xLoc, gap.YTop);
|
||||
cb.MoveTo(xLoc, gap.YTop - (gap.YTop - gap.YBottom) * YMultiplier);
|
||||
}
|
||||
_MyGaps = null;
|
||||
}
|
||||
cb.LineTo(xLoc, yBottom);
|
||||
cb.Stroke();
|
||||
if (PageListLayer != null) cb.EndLayer();
|
||||
cb.RestoreState();
|
||||
}
|
||||
|
||||
private void ResetDocStyleAndValues()
|
||||
{
|
||||
@@ -518,6 +558,10 @@ namespace Volian.Print.Library
|
||||
MyPdfContentByte.AddTemplate(MyPageCounts.AddToTemplateList(key, MyPdfWriter, txt, args.MySvgText.Font, args.MySvgText.Align, args.MySvgText.FillColor), args.MySvgScale.X(args.MySvgText.X), args.MySvgScale.Y(MyPdfContentByte, args.MySvgText.Y));
|
||||
return string.Empty;
|
||||
}
|
||||
if (args.MyText.Contains("{ROMANPAGE}"))
|
||||
{
|
||||
return args.MyText.Replace("{ROMANPAGE}", ItemInfo.RomanNumbering(1).ToLower());
|
||||
}
|
||||
if (args.MyText.Contains("{SECONDARYPAGE}") || args.MyText.Contains("{SECONDARYOF}"))
|
||||
{
|
||||
string key = "SecondaryPage." + MySection.ItemID;
|
||||
@@ -931,7 +975,7 @@ namespace Volian.Print.Library
|
||||
if (unitnum.Length > 0)
|
||||
{
|
||||
if (unitnum.Contains("#"))
|
||||
eopnum = unitnum.Replace("#", eopnum);
|
||||
eopnum = unitnum.Replace("#", eopnum);
|
||||
if (unitnum.Contains("!"))
|
||||
eopnum = unitnum.Replace("!", unitname);
|
||||
}
|
||||
@@ -1590,4 +1634,31 @@ namespace Volian.Print.Library
|
||||
_CheckOffHeaderFont = vf;
|
||||
}
|
||||
}
|
||||
public class Gap
|
||||
{
|
||||
private float _YTop;
|
||||
public float YTop
|
||||
{
|
||||
get { return _YTop; }
|
||||
set { _YTop = value; }
|
||||
}
|
||||
private float _YBottom;
|
||||
public float YBottom
|
||||
{
|
||||
get { return _YBottom; }
|
||||
set { _YBottom = value; }
|
||||
}
|
||||
public Gap(float yTop, float yBottom)
|
||||
{
|
||||
_YTop = yTop;
|
||||
_YBottom = yBottom;
|
||||
}
|
||||
}
|
||||
public class Gaps : List<Gap>
|
||||
{
|
||||
public void Add(float yTop, float yBotttom)
|
||||
{
|
||||
this.Add(new Gap(yTop, yBotttom));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user