New to Telerik UI for WinFormsStart a free 30-day trial

Definition

Namespace:Telerik.WinControls.TextPrimitiveUtils

Assembly:Telerik.WinControls.dll

Syntax:

C#
public class TinyHTMLParsers

Inheritance: objectTinyHTMLParsers

Constructors

C#
public TinyHTMLParsers()

Properties

Gets or sets the color used to display a visited hyperlink.

C#
public static Color LinkClickedColor { get; set; }

Gets or sets the color used to display a non-visited hyperlink.

C#
public static Color LinkColor { get; set; }

Methods

Parse single HTML tag and apply settings

C#
public static bool ApplyHTMLSettingsFromTag(ref FormattedText currentFormattedText, FormattedText prevText, string htmlTag, TinyHTMLParsers.TinyHTMLParsersData parserData, ref bool shouldProduceNewLine, ref string text)
Parameters:currentFormattedTextFormattedTextprevTextFormattedTexthtmlTagstringparserDataTinyHTMLParsers.TinyHTMLParsersDatashouldProduceNewLinebooltextstringReturns:

bool

check is the Text contains html command

C#
public static bool IsHTMLMode(string text)
Parameters:textstring

text to be checked

Returns:

bool

text to check

Main function for parsing process

C#
public static FormattedTextBlock Parse(string text, Color baseForeColor, string baseFont, float fontSize, ContentAlignment aligment)
Parameters:textstring

text to parse

baseForeColorColor

base Font color

baseFontstring

base font

fontSizefloat

base font size

aligmentContentAlignment

base textaligment

Returns:

FormattedTextBlock

Formatted text block that contains the whole structure

Main function for parsing process

C#
public static FormattedTextBlock Parse(string text, Color baseForeColor, string baseFont, float fontSize, FontStyle fontStyle, ContentAlignment aligment)
Parameters:textstring

text to parse

baseForeColorColor

base Font color

baseFontstring

base font

fontSizefloat

base font size

fontStyleFontStyle

base font style etc. Regular, Bold

aligmentContentAlignment

base textaligment

Returns:

FormattedTextBlock

Formatted text block that contains the whole structure

C#
public static FormattedTextBlock Parse(TextParams textParams)
Parameters:textParamsTextParamsReturns:

FormattedTextBlock