ClassXamlFormatProvider
Represents a format provider that can import and export XAML documents from a RadDocument.
Definition
Namespace:Telerik.Windows.Documents.FormatProviders.Xaml
Assembly:Telerik.Windows.Controls.RichTextBox.dll
Syntax:
public class XamlFormatProvider : DocumentFormatProviderBase, IConfigurableXamlFormatProvider, ITextBasedDocumentFormatProvider, IDocumentFormatProvider
Inheritance: objectDocumentFormatProviderBaseXamlFormatProvider
Implements:
Inherited Members
Constructors
XamlFormatProvider()
Initializes a new instance of the XamlFormatProvider class.
Declaration
public XamlFormatProvider()
Properties
CanExport
Gets a value indicating whether this instance can export.
Declaration
public override bool CanExport { get; }
Property Value
true if this instance can export; otherwise, false.
Overrides
Implements
CanImport
Gets a value indicating whether this instance can import.
Declaration
public override bool CanImport { get; }
Property Value
true if this instance can import; otherwise, false.
Overrides
Implements
ExportSettings
Gets or sets the settings used while exporting.
Declaration
public XamlExportSettings ExportSettings { get; set; }
Property Value
The export settings.
Implements
ImportSettings
Gets or sets the settings used while importing.
Declaration
public XamlImportSettings ImportSettings { get; set; }
Property Value
The import settings.
Implements
Name
Gets the name of the specific format provider.
Declaration
public override string Name { get; }
Property Value
The name.
Overrides
Implements
SupportedExtensions
Gets the extensions supported by this format provider.
Declaration
public override IEnumerable<string> SupportedExtensions { get; }
Property Value
The supported extensions.
Overrides
Implements
Methods
Export(RadDocument)
Exports the specified document to a string.
Declaration
public string Export(RadDocument document)
Parameters
document
The document.
Returns
A string containing the document.
Implements
Export(RadDocument, Stream)
Exports the specified RadDocument instance to XAML.
Declaration
public override void Export(RadDocument document, Stream output)
Parameters
document
The document.
output
The Stream the document should be saved into.
Overrides
Implements
Import(Stream)
Imports the specified Stream into a RadDocument instance.
Declaration
public override RadDocument Import(Stream input)
Parameters
input
The Stream containing the XAML document.
Returns
The generated RadDocument instance.
Overrides
Implements
Import(string)
Imports the specified XAML string.
Declaration
public RadDocument Import(string input)
Parameters
input
The string containing the XAML document.
Returns
The generated RadDocument instance.
Implements
LoadStylesheet(Stream, XamlImportSettings)
Loads a predefined stylesheet.
Declaration
public static Stylesheet LoadStylesheet(Stream input, XamlImportSettings settings = null)
Parameters
input
The stream containing the stylesheet.
settings
Returns
The loaded object.
SaveStylesheet(Stylesheet, Stream)
Saves a stylesheet.
Declaration
public static void SaveStylesheet(Stylesheet stylesheet, Stream output)
Parameters
stylesheet
The stylesheet.
output
The output stream.