![]() | InDesign SDK 20.5 |
#include <ITextState.h>

Public Types | |
| enum | { kDefaultIID = IID_ITEXTSTATE } |
Public Member Functions | |
| virtual bool16 | HasStateInfoFor (UID charStrand, TextIndex pos) const =0 |
| virtual bool16 | HasStateStyleFor (UID charStrand, TextIndex pos) const =0 |
| virtual TextIndex | LastStateInfoFor () const =0 |
| virtual void | ClearStateInfo ()=0 |
| virtual bool16 | WasDeleteState () const =0 |
| virtual void | IsDeleteState (bool16 b)=0 |
| virtual void | ApplyToState (UID charStrandUID, TextIndex where, const AttributeBossList *over)=0 |
| virtual void | ApplyToStateStyle (UID charStrandUID, TextIndex where, UID style)=0 |
| virtual UID | GetStateStyle () const =0 |
| virtual const AttributeBossList * | PeekStateOverrides () const =0 |
| virtual UID | GetStateCharStrand () const =0 |
| virtual TextIndex | GetStatePosition () const =0 |
Public Member Functions inherited from IPMUnknown | |
| virtual IPMUnknown * | QueryInterface (PMIID interfaceID) const =0 |
| virtual void | AddRef () const =0 |
| virtual void | Release () const =0 |
The ITextState interface is used to store information about attributes that are applied to the "insertion point" or the "text caret". The next insertion will use these attributes. However, if the selection is changed, then these attributes are lost forever. The ITextState interface is off the document. Each document has only 1 set of attributes active on an insertion point. It could be argued that each window could have it's own, but that is not true at this time.
| pure virtual |
Apply attributes to the caret for the a particular story and position.
| charStrandUID | is the character strand's UID in the story being set. |
| where | is the absolute position. |
| over | is a list of attributes to store at the location. |
| pure virtual |
Apply a character style to the caret for the a particular story and position.
| charStrandUID | is the character strand's UID in the story being set. |
| where | is the absolute position. |
| style | is the character style UID to store at the location. |
| pure virtual |
Clear the information in the "caret". The data is cleared after it is used during insert, for example.
| pure virtual |
What is the character strand UID that we are set for?
| pure virtual |
What is the location of the data stored here?
| pure virtual |
Get the character style applied to the ITextState object.
| pure virtual |
Is there information in this object for this story and position?
| charStrand | is the UID of the character strand of the story in question. |
| pos | is the absolute position in the story in question. |
| pure virtual |
Is there a character style stored in this object for this story and position?
| charStrand | is the UID of the character strand of the story in question. |
| pos | is the absolute position in the story in question. |
| pure virtual |
Set the flag specifying whether we are loaded due to a delete.
| b | specifies whether the data was due to a delete. |
| pure virtual |
Where was the last position? Used as a shortcut when determining whether to look at this object's data further.
| pure virtual |
Get the character attributes (local overrides) applied to the ITextState object.
| pure virtual |
Upon delete, we automatically set the text state with the delete attributes so the next insertion looks like the deleted text. There are minor behavior differences.