Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Previous Book Contents Book Index Next

Inside Macintosh: Text /
Chapter 7 - Text Services Manager / Text Services Manager Reference
Text Services Manager Routines for Client Applications / Creating and Activating TSM Documents


ActivateTSMDocument

The ActivateTSMDocument function instructs the Text Services Manager to mark the TSM document associated with a newly active window as active.

FUNCTION ActivateTSMDocument (idocID: TSMDocumentID): OSErr;
idocID
A TSM document identification number created by a prior call to the NewTSMDocument function (see page 7-50).
DESCRIPTION
When a window that has an associated TSM document becomes active, your client application must call the ActivateTSMDocument function to inform the Text Services Manager that the document is activated and is ready to use text service components.

ActivateTSMDocument calls the equivalent text service component routine ActivateTextService (see page 7-85) for all open text service components associated with the TSM document.

If a text service component has a menu, the Text Services Manager inserts the menu into the menu bar.

RESULT CODES
noErrNo error
tsmInvalidDocIDErrDocument is not a valid TSM document
SEE ALSO
For sample code that uses the ActivateTSMDocument function, see Listing 7-3 on page 7-21.


Previous Book Contents Book Index Next

© Apple Computer, Inc.
6 JUL 1996