Table of Contents

Method SetStyleEx

Namespace
Alternet.UI
Assembly
Alternet.UI.Common.dll

SetStyleEx(long, long, ITextBoxRichAttr, RichTextSetStyleFlags)

Sets the attributes for the given range, passing flags to determine how the attributes are set.

public virtual bool SetStyleEx(long startRange, long endRange, ITextBoxRichAttr style, RichTextSetStyleFlags flags = RichTextSetStyleFlags.WithUndo)

Parameters

startRange long
endRange long
style ITextBoxRichAttr
flags RichTextSetStyleFlags

Returns

bool

Remarks

The end point of range is specified as the last character position of the span of text, plus one. So, for example, to set the style for a character at position 5, use the range (5,6). flags may contain a bit list of the following values: None, WithUndo, Optimize, ParagraphsOnly, CharactersOnly, Reset, Remove.