Class
RtfFormatProvider

Imports and exports flow documents in Rich Text Format (RTF) with support for text formatting, tables, images, and document structure.

Definition

Namespace:Telerik.Windows.Documents.Flow.FormatProviders.Rtf

Assembly:Telerik.Windows.Documents.Flow.dll

Syntax:

cs-api-definition
public class RtfFormatProvider : TextBasedFormatProviderBase<RadFlowDocument>, IFormatProvider<RadFlowDocument>, ITextBasedFormatProvider<RadFlowDocument>

Inheritance: objectFormatProviderBase<RadFlowDocument>TextBasedFormatProviderBase<RadFlowDocument>RtfFormatProvider

Implements: IFormatProvider<RadFlowDocument>ITextBasedFormatProvider<RadFlowDocument>

Inherited Members TextBasedFormatProviderBase<RadFlowDocument>.Import(string)TextBasedFormatProviderBase<RadFlowDocument>.Import(string, TimeSpan?)TextBasedFormatProviderBase<RadFlowDocument>.Export(RadFlowDocument)TextBasedFormatProviderBase<RadFlowDocument>.Export(RadFlowDocument, TimeSpan?)FormatProviderBase<RadFlowDocument>.Import(Stream)FormatProviderBase<RadFlowDocument>.Import(Stream, TimeSpan?)FormatProviderBase<RadFlowDocument>.Export(RadFlowDocument, Stream)FormatProviderBase<RadFlowDocument>.Export(RadFlowDocument, Stream, TimeSpan?)

Constructors

RtfFormatProvider()

Initializes a new instance of the RtfFormatProvider class with default export settings.

Declaration

cs-api-definition
public RtfFormatProvider()

Properties

CanExport

Gets whether this provider can export to RTF; always returns true.

Declaration

cs-api-definition
public override bool CanExport { get; }

Property Value

bool

The value indicating whether can export.

Overrides FormatProviderBase<RadFlowDocument>.CanExport

CanImport

Gets whether this provider can import RTF documents; always returns true.

Declaration

cs-api-definition
public override bool CanImport { get; }

Property Value

bool

The value indicating whether can import.

Overrides FormatProviderBase<RadFlowDocument>.CanImport

ExportSettings

Gets or sets the configuration options for RTF export, such as image compatibility mode.

Declaration

cs-api-definition
public RtfExportSettings ExportSettings { get; set; }

Property Value

RtfExportSettings

The export settings.

SupportedExtensions

Gets the file extensions supported by this provider; returns ".rtf".

Declaration

cs-api-definition
public override IEnumerable<string> SupportedExtensions { get; }

Property Value

IEnumerable<string>

The supported extensions.

Overrides FormatProviderBase<RadFlowDocument>.SupportedExtensions

Methods

ExportOverride(RadFlowDocument, Stream)

Exports the specified document.

Declaration

cs-api-definition
[Obsolete("This method is obsolete. Please use ExportOverride(RadFlowDocument document, Stream output, CancellationToken cancellationToken) instead.")]
protected override void ExportOverride(RadFlowDocument document, Stream output)

Parameters

document

RadFlowDocument

The document.

output

Stream

The output.

Overrides FormatProviderBase<RadFlowDocument>.ExportOverride(RadFlowDocument, Stream)

ExportOverride(RadFlowDocument, Stream, CancellationToken)

Exports the specified document.

Declaration

cs-api-definition
protected override void ExportOverride(RadFlowDocument document, Stream output, CancellationToken cancellationToken)

Parameters

document

RadFlowDocument

The document.

output

Stream

The output.

cancellationToken

CancellationToken

The cancellation token used to cancel the operation.

Overrides FormatProviderBase<RadFlowDocument>.ExportOverride(RadFlowDocument, Stream, CancellationToken)

ImportOverride(Stream)

Imports the specified input.

Declaration

cs-api-definition
[Obsolete("This method is obsolete. Please use ImportOverride(Stream input, CancellationToken cancellationToken) instead.")]
protected override RadFlowDocument ImportOverride(Stream input)

Parameters

input

Stream

The input.

Returns

RadFlowDocument

The imported document.

Overrides FormatProviderBase<RadFlowDocument>.ImportOverride(Stream)

ImportOverride(Stream, CancellationToken)

Imports the specified input.

Declaration

cs-api-definition
protected override RadFlowDocument ImportOverride(Stream input, CancellationToken cancellationToken)

Parameters

input

Stream

The input.

cancellationToken

CancellationToken

The cancellation token used to cancel the operation.

Returns

RadFlowDocument

The imported document.

Overrides FormatProviderBase<RadFlowDocument>.ImportOverride(Stream, CancellationToken)