PdfRpt.HeaderTemplates.XHtmlHeaderProvider.createTable C# (CSharp) Method

createTable() private method

private createTable ( string html, XHeaderBasicProperties basicProperties ) : PdfGrid
html string
basicProperties PdfRpt.Core.Contracts.XHeaderBasicProperties
return PdfRpt.Core.Contracts.PdfGrid
        private PdfGrid createTable(string html, XHeaderBasicProperties basicProperties)
        {
            var table = new PdfGrid(1)
            {
                RunDirection = (int)basicProperties.RunDirection,
                WidthPercentage = basicProperties.TableWidthPercentage
            };
            var htmlCell = new XmlWorkerHelper
            {
                Html = html,
                RunDirection = basicProperties.RunDirection,
                CssFilesPath = basicProperties.CssFilesPath,
                ImagesPath = basicProperties.ImagesPath,
                InlineCss = basicProperties.InlineCss,
                DefaultFont = basicProperties.PdfFont.Fonts[0]
            }.RenderHtml();
            htmlCell.Border = 0;
            table.AddCell(htmlCell);

            if (basicProperties.ShowBorder)
                return table.AddBorderToTable(basicProperties.BorderColor, basicProperties.SpacingBeforeTable);
            table.SpacingBefore = basicProperties.SpacingBeforeTable;

            return table;
        }