PdfRpt.ColumnsItemsTemplates.WingdingsSymbolField.RenderingCell C# (CSharp) Method

RenderingCell() public method

Custom cell's content template as a PdfPCell
public RenderingCell ( PdfRpt.Core.Contracts.CellAttributes attributes ) : PdfPCell
attributes PdfRpt.Core.Contracts.CellAttributes
return iTextSharp.text.pdf.PdfPCell
        public PdfPCell RenderingCell(CellAttributes attributes)
        {
            if (OnSelectSymbol == null)
                throw new InvalidOperationException("Please set the OnSelectSymbol formula.");

            var font = FontFactory.GetFont(WingdingsFontPath, BaseFont.IDENTITY_H, true, attributes.BasicProperties.PdfFont.Size, Font.NORMAL, attributes.BasicProperties.FontColor);
            var symbol = (int)OnSelectSymbol.Invoke(attributes.RowData.TableRowData);
            return new PdfPCell(new Phrase(new Chunk((char)symbol, font)));
        }