Version

Properties for Configuring a TextDocument

Topic Overview

Purpose

This topic uses descriptive text to illustrate the exposed TextDocument class properties to enable custom configuration.

IsReadOnly Property

Description

The IsReadOnly property, when set to “true”, prevents the document from accepting any changes made to it.

Language Property

The Language property identifies the code language (for example, C#, Visual Basic, etc…) that applies to a given document. If the Language property is not set it treats the document as a simple text file with no syntax rules. In this case, the property will return an instance of the PlainTextLanguage class.

UndoManager Property

The UndoManager property supports unlimited undo/redo of changes.

Note
Note:

By default, each instance of a TextDocument creates its own instance of an UndoManager. However, this property is configurable, so it is possible to share a single instance of an UndoManager across multiple documents.

Related Content

Topics

The following topic provides additional information related to this topic.

Topic Purpose

This topic describes the Infragistics Syntax Parsing Engine’s main class, TextDocument, and contains links to topics that outline its most important methods, events and properties.

This topic uses descriptive text and code snippets to illustrate the TextDocument class events.

This topic uses descriptive text and code snippets to illustrate the TextDocument class methods for text modification

This topic uses descriptive text and code snippets to illustrate how to provide use a RichTextBox control to highlight keywords in a document according to a specific language.