Click to Rate and Give Feedback
MSDN
MSDN Library
User Interface
Windows Controls
Control Library
Rich Edit
Interfaces
ITextServices
ITextServices Interface

Extends the Text Object Model (TOM) to provide extra functionality for windowless operation.

ITextServices Members

OnTxInPlaceActivate The ITextServices::OnTxInPlaceActivate method notifies the text services object that this control is in-place active.
OnTxInPlaceDeactivate The ITextServices::OnTxInPlaceDeactivate method notifies the text services object that this control is no longer in-place active.
OnTxPropertyBitsChange The ITextServices::OnTxPropertyBitsChange method sets properties (represented by bits) for the control.
OnTxSetCursor The ITextServices::OnTxSetCursor method notifies the text services object to set the cursor.
OnTxUIActivate The ITextServices::OnTxUIActivate method informs the text services object that the control is now UI active.
OnTxUIDeactivate The ITextServices::OnTxUIDeactivate method informs the text services object that the control is no longer UI active.
TxDraw The ITextServices::TxDraw method draws the text services object.
TxGetBaseLinePos The ITextServices::TxGetBaseLinePos method gets the base line position of the first visible line, in pixels, relative to the text services client rectangle. This permits aligning controls on their base lines.
TxGetCachedSize The ITextServices::TxGetCachedSize method returns the cached drawing size (if any) that text services is using. Typically, this will be the size of the last client rectangle used in ITextServices::TxDraw, ITextServices::OnTxSetCursor, and so forth, although it is not guaranteed to be.
TxGetCurTargetX The ITextServices::TxGetCurTargetX method gets the target x position, that is, the current horizontal position of the caret.
TxGetDropTarget The ITextServices::TxGetDropTarget method gets the drop target for the text control.
TxGetHScroll The ITextServices::TxGetHScroll method returns horizontal scroll bar information.
TxGetNaturalSize The ITextServices::TxGetNaturalSize method allows a control to be resized so it fits its content appropriately.
TxGetText The ITextServices::TxGetText method returns all of the Unicode plain text in the control as a BSTR.
TxGetVScroll The ITextServices::TxGetVScroll method returns vertical scroll bar state information.
TxQueryHitPoint The ITextServices::TxQueryHitPoint method tests whether a specified point is within the rectangle of the text services object.
TxSendMessage The ITextServices::TxSendMessage method is used by the window host to forward messages sent from its window to the text services object.
TxSetText The ITextServices::TxSetText method sets all of the text in the control.

Remarks

In conjunction with the ITextHost interface, ITextServices provides the means by which a rich edit control can be used without creating a window.

When to Implement

Applications do not implement the ITextServices interface.

When to Use

Applications can call the CreateTextServices function to create a text services object. To retrieve an ITextServices pointer, call QueryInterface on the private IUnknown pointer returned by CreateTextServices. You can then call the ITextServices methods to send messages to the text services object.

Interface Information

Minimum DLL Versionmsftedit.dll
Inherits fromIUnknown
Headertextserv.h
Minimum operating systems Windows 95 with Rich Edit 2.0, Windows 98, Windows NT 4.0

See Also

Windowless Rich Edit Controls Overview
Tags What's this?: Add a tag
Community Content   What is Community Content?
Add new content RSS  Annotations
Processing
© 2009 Microsoft Corporation. All rights reserved. Terms of Use | Trademarks | Privacy Statement | Site Feedback
Page view tracker