API Reference

Class

RtfToHtmlOptions

Namespace OfficeIMO.Html
Assembly OfficeIMO.Html
Modifiers sealed

Controls RTF to semantic HTML conversion.

Inheritance

  • Object
  • RtfToHtmlOptions

Usage

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

Accepted by parameters

Constructors

Methods

public RtfToHtmlOptions Clone() #
Returns: RtfToHtmlOptions

Creates a reusable copy of the current save options.

Returns

A new RtfToHtmlOptions with the same configuration values.

public static RtfToHtmlOptions CreateRoundTripProfile() #
Returns: RtfToHtmlOptions

Creates options for a trusted OfficeIMO HTML round trip. The output can contain private metadata and binary payloads and must not be published without sanitization.

public static RtfToHtmlOptions CreateWebSafeProfile() #
Returns: RtfToHtmlOptions

Creates options for publishing untrusted RTF as semantic HTML. Private OfficeIMO round-trip metadata and inline data URI images are disabled, and only web and mail hyperlinks are allowed.

Properties

public Boolean FragmentOnly { get; set; } #

Writes only the body fragment instead of a complete HTML document.

public Boolean IncludeMetadata { get; set; } #

Includes document metadata when a full HTML document is requested.

public Boolean PreferEncapsulatedHtml { get; set; } #

Prefers Outlook/Exchange HTML encapsulated in the RTF transport over its plain-text fallback. The encapsulated HTML is always reparsed through the bounded HTML reader and current URL policy.

public String Title { get; set; } #

Optional HTML document title. When unset, the RTF title is used.

public HtmlUrlPolicy UrlPolicy { get; set; } #

URL policy applied to every hyperlink and caller-supplied image source written to HTML. The default is the restrictive web-only policy.

public Boolean IncludeRoundTripMetadata { get; set; } #

Includes private data-officeimo-rtf-* metadata used for trusted fidelity round trips. This can include encoded object and image payloads and is disabled by default.

public Boolean EmbedImagesAsDataUri { get; set; } #

Embeds supported images as data URI values. Disabled by default for web-safe output.

public Int32 MaxEmbeddedImageBytes { get; set; } #

Maximum size of one image that may be embedded as a data URI.

public Func<RtfImage, String> ImageSourceResolver { get; set; } #

Optional callback that stores or maps an RTF image and returns its HTML source URL. Returned URLs are validated using UrlPolicy.

public String NewLine { get; set; } #

Newline sequence used by the generated HTML.