Class RtfHtmlSettings
Settings used when converting RTF to HTML
Inherited Members
Namespace: SharpRtfConvert
Assembly: SharpRtfConvert.dll
Syntax
public class RtfHtmlSettings : HtmlWriterSettings
Constructors
| Edit this page View SourceRtfHtmlSettings()
Create a new RtfHtmlSettings object
Declaration
public RtfHtmlSettings()
Properties
| Edit this page View SourceAttachmentRenderer
Callback used when building the HTML to render an e-mail attachment
Declaration
public Action<int, XmlWriter> AttachmentRenderer { get; set; }
Property Value
| Type | Description |
|---|---|
| Action<int, XmlWriter> |
ElementTags
Mapping of HTML tags to use for various document element types
Declaration
public Dictionary<ElementType, HtmlTag> ElementTags { get; }
Property Value
| Type | Description |
|---|---|
| Dictionary<ElementType, HtmlTag> |
ImageUriGetter
Callback used to get the URI for a picture stored in RTF. This could be
a data URI that contains the binary data of the picture, or a link to
an external file. Return null to omit the image from the output.
Declaration
public Func<Picture, string?> ImageUriGetter { get; set; }
Property Value
| Type | Description |
|---|---|
| Func<Picture, string> |
OnImageSkipped
Called when an image is omitted from the HTML output because
ImageUriGetter returned null. Use this to log
or surface unsupported image formats (e.g. EMF, WMF) to callers.
The Type and MimeType() identify the format.
Declaration
public Action<Picture>? OnImageSkipped { get; set; }
Property Value
| Type | Description |
|---|---|
| Action<Picture> |
Methods
| Edit this page View SourceWithFullDocument()
Declaration
public RtfHtmlSettings WithFullDocument()
Returns
| Type | Description |
|---|---|
| RtfHtmlSettings |