ClassRegexTagger
Class
Represents a RegexTagger that processes and tags text based on regular expressions.
Definition
Namespace:Telerik.Windows.Documents.Model.Code
Assembly:Telerik.Windows.Controls.RichTextBox.dll
Syntax:
cs-api-definition
public class RegexTagger : TaggerBase<ClassificationTag>, ITagger<ClassificationTag>
Inheritance: objectTaggerBase<ClassificationTag>RegexTagger
Implements:
Inherited Members
Constructors
RegexTagger(Dictionary<Regex, ClassificationType>)
Declaration
cs-api-definition
public RegexTagger(Dictionary<Regex, ClassificationType> regexToClassificationType)
Parameters
regexToClassificationType
Methods
GetKeywordsRegex(IEnumerable<string>)
Creates regular expression by a list of keywords.
Declaration
cs-api-definition
public static Regex GetKeywordsRegex(IEnumerable<string> keywords)
Parameters
keywords
A list of keywords.
Returns
GetTags(IDocumentEditor)
Retrieves a collection of tags from the specified document editor using regex tagging.
Declaration
cs-api-definition
public override IEnumerable<TaggedTextRange<ClassificationTag>> GetTags(IDocumentEditor editor)
Parameters
editor
The document editor from which to retrieve the tags.
Returns
IEnumerable<TaggedTextRange<ClassificationTag>>
A collection of tags extracted from the document editor.
Overrides