This commit is contained in:
2011-05-19 13:36:09 +00:00
parent 1d84dd29e3
commit 1b1e5668d1
4 changed files with 12 additions and 8 deletions

View File

@@ -47,9 +47,8 @@ namespace Volian.Print.Library
//Console.WriteLine("'{0}','{1}'", CharToAsc(MyBox.BoxStyle), MyParent.MyItemInfo.ShortPath);
float top = CalculateYOffset(yPageStart, yTopMargin) - (7*MyPageHelper.YMultiplier);
float bottom = top - (Height * MyPageHelper.YMultiplier);
float leftmargin = (float)MyParent.MyItemInfo.MyDocStyle.Layout.LeftMargin + 3;
float left = (float)(MyBox.Start == null ? MyParent.MyItemInfo.MyDocStyle.Layout.LeftMargin : leftmargin + MyBox.Start);
float right = leftmargin + (float)(MyBox.End ?? DefEnd);
float left = (float)((MyBox.Start ?? 0) + MyParent.MyItemInfo.MyDocStyle.Layout.LeftMargin);
float right = (float)MyParent.MyItemInfo.MyDocStyle.Layout.LeftMargin + (float)(MyBox.End ?? DefEnd);
iTextSharp.text.Color boxColor = new iTextSharp.text.Color(PrintOverride.OverrideBoxColor(System.Drawing.Color.Black));
cb.SetColorStroke(boxColor);
if (DefBox != null)
@@ -70,11 +69,13 @@ namespace Volian.Print.Library
break;
default:
// For other than OHLP/HLP. For those not matching the HLP Boxes
throw new Exception("Missing vlnBox handler");
Console.WriteLine("NO BOXES");
break;
//throw new Exception("Missing vlnBox handler");
}
const float llxOffset = 3;
cb.SetLineWidth(lineThickness);
cb.Rectangle(left + llxOffset, bottom + (lineThickness / 2), right - left - llxOffset, (Height - lineThickness) * MyPageHelper.YMultiplier);
cb.Rectangle(left + llxOffset, bottom + (lineThickness / 2), right - left, (Height - lineThickness) * MyPageHelper.YMultiplier);
}
cb.Stroke();
if (textLayer != null) cb.EndLayer();