/// <summary> /// Add text to paragraph contents /// </summary> public void AppendText(RtfParagraphContentBase text) { if (paragraphs.Count == 0) { contents.Add(text); } else { paragraphs[paragraphs.Count - 1].AppendText(text); } }
/// <summary> /// Initializes a new instance of ESCommon.Rtf.RtfTableCell class. /// </summary> /// <param name="width">Cell width in centimeters.</param> /// <param name="text">Text displayed in the cell.</param> /// <param name="style">Style applied to the cell.</param> public RtfTableCell(float width, RtfParagraphContentBase text, RtfTableCellStyle style) : base(text, style.DefaultParagraphFormatting) { Initialize(style); _definition.Width = TwipConverter.ToTwip(width, MetricUnit.Centimeter); }
/// <summary> /// Initializes a new instance of ESCommon.Rtf.RtfTableCell class. /// </summary> /// <param name="text">Text displayed in the cell.</param> /// <param name="style">Style applied to the cell.</param> public RtfTableCell(RtfParagraphContentBase text, RtfTableCellStyle style) : base(text, style.DefaultParagraphFormatting) { Initialize(style); }
/// <summary> /// Initializes a new instance of ESCommon.Rtf.RtfTableCell class. /// </summary> /// <param name="width">Cell width in centimeters.</param> /// <param name="text">Text displayed in the cell.</param> public RtfTableCell(float width, RtfParagraphContentBase text) : base(text) { Initialize(); _definition.Width = TwipConverter.ToTwip(width, MetricUnit.Centimeter); }
/// <summary> /// Initializes a new instance of ESCommon.Rtf.RtfTableCell class. /// </summary> /// <param name="text">Text displayed in the cell.</param> public RtfTableCell(RtfParagraphContentBase text) : base(text) { Initialize(); }
/// <summary> /// Add a new paragraph with inherited formatting /// </summary> public void AppendParagraph(RtfParagraphContentBase text) { this.AppendParagraph(new RtfParagraph(text)); }
/// <param name="text">Text to add to paragraph contents.</param> public RtfParagraphBase(RtfParagraphContentBase text) : this() { AppendText(text); }
/// <param name="text">Text to add to paragraph contents.</param> public RtfParagraph(RtfParagraphContentBase text) : base(text) { }
/// <param name="text">Text to add to paragraph contents</param> /// <param name="formatting">Paragraph formatting</param> public RtfFormattedParagraph(RtfParagraphContentBase text, RtfParagraphFormatting formatting) : base(text) { _formatting = formatting; }
/// <summary> /// Adds a new ESCommon.Rtf.RtfTableCell with specified text to the collection. /// </summary> public void Add(RtfParagraphContentBase text) { this.Add(new RtfTableCell(text)); }