InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
ITextFocusManager Class Referenceabstract

#include <ITextFocusManager.h>

Inheritance diagram for ITextFocusManager:
IPMUnknown

Classes

struct  FocusUpdateInfo
 

Public Types

enum  { kDefaultIID = IID_ITEXTFOCUSMANAGER }
 
enum  FocusUpdateType { kInvalidUpdateType = 0, kInserted, kDeleted, kAppliedAttrs }
 
typedef K2Vector< FocusUpdateInfoFocusUpdateInfoList
 

Public Member Functions

virtual ITextFocusNewFocus (const RangeData &range, ClassID focusClass=kInvalidClass)=0
 
virtual void AddFocus (ITextFocus *f)=0
 
virtual void RemoveFocus (ITextFocus *f)=0
 
virtual int32 GetFocusCount () const =0
 
virtual ITextFocusQueryNthFocus (int32 nAt)=0
 
virtual void Inserted (TextIndex start, int32 count, bool16 allowNotify=kTrue)=0
 
virtual void Deleted (TextIndex start, int32 count, bool16 allowNotify=kTrue)=0
 
virtual void AttributeApplied (TextIndex start, int32 count, bool16 allowNotify=kTrue)=0
 
virtual void StoryThreadCreated (TextIndex at, int32 len)=0
 
virtual void Update (const FocusUpdateInfoList &updateInfoList, bool16 allowNotify)=0
 
virtual void DeRegisterTextFoci ()=0
 
- Public Member Functions inherited from IPMUnknown
virtual IPMUnknownQueryInterface (PMIID interfaceID) const =0
 
virtual void AddRef () const =0
 
virtual void Release () const =0
 

Detailed Description

TextFocusManager maintains a list of ITextFocus objects and updates them accordingly when characters are inserted/deleted. ITextFocusManager is an interface of the TextModelBoss.

See Also
ITextFocus
IFocusCache

Member Typedef Documentation

A list of FocusUpdateInfo allows a series of changes to be done at one time – e.g. a Change-All operation.

Member Enumeration Documentation

FocusUpdateType allows a series of changes to be done at one time – e.g. a Change-All operation.

Member Function Documentation

virtual void ITextFocusManager::AddFocus (ITextFocusf)
pure virtual

Add the pre-existing ITextFocus boss to this list. It is assumed that the text focus will be for this manager's story.

Parameters
fis the textfocus object to add.
virtual void ITextFocusManager::AttributeApplied (TextIndex start,
int32 count,
bool16 allowNotify = kTrue 
)
pure virtual

The textmodel calls this to adjust the textfoci to reflect text being formatted.

Parameters
startis the location of the format change.
countis the number of characters changed..
allowNotifyspecifies whether the event should be broadcast.
virtual void ITextFocusManager::Deleted (TextIndex start,
int32 count,
bool16 allowNotify = kTrue 
)
pure virtual

The textmodel calls this to adjust the textfoci to reflect text being deleted.

Parameters
startis the location of the delete.
countis the number of characters deleted.
allowNotifyspecifies whether the event should be broadcast.
virtual int32 ITextFocusManager::GetFocusCount () const
pure virtual

Count how many text foci there are on this story, managed by this list.

Returns
the number of text foci.
virtual void ITextFocusManager::Inserted (TextIndex start,
int32 count,
bool16 allowNotify = kTrue 
)
pure virtual

The textmodel calls this to adjust the textfoci to reflect text being inserted.

Parameters
startis the location of the insert.
countis the number of characters inserted.
allowNotifyspecifies whether the event should be broadcast.
virtual ITextFocus* ITextFocusManager::NewFocus (const RangeDatarange,
ClassID focusClass = kInvalidClass 
)
pure virtual

Create a new Text Focus managed by this list.

Parameters
rangespecifies where the TextFocus should be located. allows alternate TextFocusBoss classes to be used.
Returns
an AddRef'd textfocus.
virtual ITextFocus* ITextFocusManager::QueryNthFocus (int32 nAt)
pure virtual

Get one of the foci managed by this list.

Parameters
nAtis the index of the text foci requested.
Returns
the n'th AddRef'd ITextFocus interface.
virtual void ITextFocusManager::RemoveFocus (ITextFocusf)
pure virtual

Remove the pre-existing ITextFocus boss from this list.

Parameters
fis the textfocus object to remove.
virtual void ITextFocusManager::StoryThreadCreated (TextIndex at,
int32 len 
)
pure virtual

The textmodel calls this when new story threads are created.

Parameters
atis the location of the new story thread.
lenis the length of the new story thread.
virtual void ITextFocusManager::Update (const FocusUpdateInfoListupdateInfoList,
bool16 allowNotify 
)
pure virtual

Update following a sequence of text model changes.

Parameters
updateInfoListis a list of operations performed.
allowNotifyspecifies whether the event should be broadcast.