From 73f50dff80e7cf073aa35e5ee254e39ede3d238a Mon Sep 17 00:00:00 2001 From: Kathy Date: Wed, 9 Mar 2011 12:10:05 +0000 Subject: [PATCH] --- PROMS/Volian.Print.Library/Rtf2Pdf.cs | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/PROMS/Volian.Print.Library/Rtf2Pdf.cs b/PROMS/Volian.Print.Library/Rtf2Pdf.cs index 1350cee0..a058f2fa 100644 --- a/PROMS/Volian.Print.Library/Rtf2Pdf.cs +++ b/PROMS/Volian.Print.Library/Rtf2Pdf.cs @@ -124,6 +124,21 @@ namespace Volian.Print.Library if (textLayer != null) cb.EndLayer(); return bottom; } + public static float GridAt(PdfContentByte cb, vlnTable myGrid, float x, float y, float width, float height, string debugText, float yBottomMargin, bool hasBorder) + { + VlnSvgPageHelper _MyPageHelper = cb.PdfWriter.PageEvent as VlnSvgPageHelper; + PdfLayer textLayer = _MyPageHelper == null ? null : _MyPageHelper.TextLayer; + float left = x + Offset.X; + float top = y + Offset.Y; + float right = left + width; + float bottom = top - height; + ColumnText myColumnText = new ColumnText(cb); + myColumnText.SetSimpleColumn(left, top, left + width, yBottomMargin); + if (textLayer != null) cb.BeginLayer(textLayer); + myGrid.ToPdf(myColumnText, left, top); + if (textLayer != null) cb.EndLayer(); + return bottom; + } private static void DrawPdfDebug(PdfContentByte cb, float left, float top, float right, float bottom, string debugText, float yDescent) { VlnSvgPageHelper _MyPageHelper = cb.PdfWriter.PageEvent as VlnSvgPageHelper;