TextDocument Class |
Namespace: TextObjectModel
The TextDocument type exposes the following members.
Name | Description | |
---|---|---|
AttachMsgFilter |
(TOM 2 only)
Attaches a new message filter to the edit instance.
All window messages that the edit instance receives are forwarded to the message filter.
| |
BeginEditCollection |
Turns on edit collection (also called undo grouping).
| |
BeginUpdate |
Increments the freeze count. If the freeze count is nonzero, screen updating is disabled.
| |
CheckTextLimit |
(TOM 2 only)
Checks whether the number of characters to be added would exceed the maximum text limit.
| |
Dispose | Releases all resources used by the TextDocument | |
Dispose(Boolean) | Releases the unmanaged resources used by the TextDocument and optionally releases the managed resources | |
EndEditCollection |
Turns off edit collection (also called undo grouping).
| |
EndUpdate |
Decrements the freeze count. If the freeze count goes to zero, screen updating is enabled.
| |
Finalize | (Overrides ObjectFinalize.) | |
FromComObject |
Creates a TextDocument instance from the specified COM object.
| |
FromIUnknown |
Creates a TextDocument instance from a pointer to an IUnknown object.
| |
FromRichEditControl |
Creates a TextDocument instance from a RichEdit control.
| |
FromRichTextBox |
Creates a TextDocument instance from the specified
RichTextBox control.
| |
GetClientRectangle |
(TOM 2 only)
Retrieves the client rectangle of the rich edit control.
| |
GetDisplays |
(TOM 2 only)
Gets the displays collection for this Text Object Model (TOM) engine instance.
| |
GetEffectColor |
(TOM 2 only)
Retrieves the color used for special text attributes.
| |
GetNewStory |
(TOM 2 only)
Gets a new story.
| |
GetPreferredFont |
(TOM 2 only)
Retrieves the preferred font for a particular character repertoire and character position.
| |
GetStory |
(TOM 2 only)
Retrieves the story that corresponds to a particular index.
| |
GetStrings |
(TOM 2 only)
Gets a new collection of rich-text strings.
| |
New |
Opens a new document.
| |
Notify |
(TOM 2 only)
Notifies the TOM engine client of particular IME events.
| |
Open |
Opens a specified document.
| |
Range |
Retrieves a text range object for a specified range of content in the active story of the document.
| |
RangeFromPoint |
Retrieves a range for the content at or nearest to the specified point on the screen.
| |
Redo |
Performs a specified number of redo operations.
| |
ResumeUndo |
Resumes undo processing.
| |
Save |
Saves the document.
| |
SetEffectColor |
(TOM 2 only)
Specifies the color to use for special text attributes.
| |
SetIMEInProgress |
(TOM 2 only)
Sets the state of the IME in-progress flag.
| |
SuspendUndo |
Suspends undo processing.
| |
SysBeep |
(TOM 2 only)
Generates a system beep.
| |
ToString |
Returns the name of the document, or "Document" if Name is empty.
(Overrides ObjectToString.) | |
Undo |
Performs a specified number of undo operations.
| |
Update |
(TOM 2 only)
Updates the selection and caret.
| |
UpdateWindow |
(TOM 2 only)
Notifies the client that the view has changed and the client should update the view if the TOM engine is in-place active.
|
Name | Description | |
---|---|---|
ActiveStory |
(TOM 2 only)
Gets or sets the active story; that is, the story that receives keyboard and mouse input.
| |
AdvancedTypographyEnabled |
(TOM 2 only)
Gets or sets a value indicating whether advanced typography
(special line breaking and line formatting) is turned on.
| |
CaretType |
(TOM 2 only)
Gets or sets the caret type.
| |
DefaultTabStop |
Gets or sets the default tab width.
| |
DocumentFont |
(TOM 2 only)
Gets or sets a TextFont that provides the default character format information for this instance of the TOM engine.
| |
DocumentPara |
(TOM 2 only)
Gets or sets a TextPara that provides the default paragraph format information for this instance of the TOM engine.
| |
EastAsianFlags |
(TOM 2 only)
Gets the East Asian flags.
| |
EntireRange |
Returns a TextRange representing the entire document.
| |
Generator |
(TOM 2 only)
Gets the name of the TOM engine.
| |
MainStory |
(TOM 2 only) Gets the main story.
| |
MathProperties |
Provides access to the math properties for the document.
| |
Name |
Gets the file name of this document.
| |
NotificationMode |
(TOM 2 only)
Gets or sets the notification mode.
| |
Properties |
Provides access to the properties of the document.
| |
Saved |
Gets or sets a value that indicates whether changes have been made since the file was last saved.
| |
Selection |
Gets the active selection.
| |
StoryRanges |
Gets a TextStoryRanges which enumerates through the stories in the document.
| |
SupportedVersion |
Gets a value indicating which version of the Text Object Model (TOM)
is supported by the current document.
| |
WindowHandle |
(TOM 2 only)
Gets the handle of the window that the TOM engine is using to display output.
|
Managed wrapper class for the COM interface ITextDocument, including ITextDocument2 functionality.
You can obtain an instance TextDocument in a number of ways: