Class
HtmlImportSettings

Configures HTML import behavior, including generic font mappings, external resource loading, and CSS stylesheet handling.

Definition

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

Assembly:Telerik.Windows.Documents.Flow.dll

Syntax:

cs-api-definition
public class HtmlImportSettings

Inheritance: objectHtmlImportSettings

Constructors

HtmlImportSettings()

Initializes a new instance of the HtmlImportSettings class.

Declaration

cs-api-definition
public HtmlImportSettings()

Properties

DefaultStyleSheet

Gets or sets the CSS stylesheet applied as default styles during HTML import, establishing baseline formatting rules.

Declaration

cs-api-definition
public string DefaultStyleSheet { get; set; }

Property Value

string

The default style sheet that will be used during the import.

GenericFonts

Gets the mappings from HTML generic font families to actual fonts used during import.

Declaration

cs-api-definition
public GenericHtmlFonts GenericFonts { get; }

Property Value

GenericHtmlFonts

The generic fonts collection.

ReplaceNonBreakingSpaces

Gets or sets whether non-breaking space characters (U+00A0) are converted to regular spaces during import (default is false).

The default value is false.

Declaration

cs-api-definition
public bool ReplaceNonBreakingSpaces { get; set; }

Property Value

bool

Indicates whether non breaking spaces should be replaced.

Events

LoadFromUri

Occurs when loading from URL.

Declaration

cs-api-definition
[Obsolete("This event will be removed in R1 2022. For loading images from Uris use the new LoadImageFromUri and for loading external stylesheets - LoadStyleSheetFromUri", false)]
public event EventHandler<LoadFromUriEventArgs> LoadFromUri

Event Value

EventHandler<LoadFromUriEventArgs>

LoadImageFromUri

Raised when the provider encounters an image URI during import, allowing custom image retrieval logic.

Declaration

cs-api-definition
public event EventHandler<LoadImageFromUriEventArgs> LoadImageFromUri

Event Value

EventHandler<LoadImageFromUriEventArgs>

LoadStyleSheetFromUri

Raised when the provider encounters an external stylesheet URI during import, allowing custom CSS retrieval logic.

Declaration

cs-api-definition
public event EventHandler<LoadStyleSheetFromUriEventArgs> LoadStyleSheetFromUri

Event Value

EventHandler<LoadStyleSheetFromUriEventArgs>