IAgentCharacterEx::Think
[Microsoft Agent is deprecated as of Windows 7, and may be unavailable in subsequent versions of Windows.]
HRESULT Think(
BSTR bszText, // text to think
long * pdwReqID // address of a request ID
);
Displays the character's thought word balloon with the specified text.
- Returns S_OK to indicate the operation was successful.
-
bszText
-
The text to appear in the character's thought balloon.
-
pdwReqID
-
Address of a variable that receives the Think request ID.
Like the IAgentCharacter::Speak method, the Think method is a queued request that displays text in a word balloon, except that thoughts display in a special thought balloon. The thought balloon supports only the Bookmark speech control tag (\Mrk) and ignores any other speech control tags. Unlike IAgentCharacter::Speak, the Think method does not change the character's animation state.
The IAgentBalloon settings also apply to the appearance style of the thought balloon. For example, the balloon's Enabled property must also be True for the text to display.
Microsoft Agent's automatic word breaking in the word balloon breaks words using white-space characters (for example, space and tab). However, it may break a word to fit the balloon as well. In languages like Japanese, Chinese, and Thai, where spaces are not used to break words, insert a Unicode zero width space character (0x200B) between characters to define logical word breaks.
Note
Set the character's language ID (using IAgentCharacterEx::SetLanguageID before using the IAgentCharacter::Speak method to ensure appropriate text display within the word balloon.
See Also
IAgentBalloon::GetEnabled, IAgentBalloonEx::SetStyle, IAgentCharacter::Speak