SPGRAMMARSTATE (Windows CE 5.0)
This enumeration defines grammar states. The states are used in setting and restoring grammars.
typedef enum SPGRAMMARSTATE{ SPGS_ENABLED = 0, SPGS_DISABLED = 1, SPGS_EXCLUSIVE = 3} SPGRAMMARSTATE;
Elements
- SPGS_ENABLED
Activate all the rules in the grammar for the SR engine so that the grammar can receive recognitions. This is the default. - SPGS_DISABLED
Deactivate all the rules in the grammar for the SR engine. SAPI retains the current rule activation state, so that a reset to SPGS_ENABLED restores the grammar rules to each of the original activation states. While the grammar state is set to SPGS_DISABLED, the application can still start and deactivate rule. The effect is not communicated to the SR engine (but retained by SAPI) until the grammar is enabled again. - SPGS_EXCLUSIVE
Turn off all rules that are not part of the current grammar. SAPI disables all other grammars in the system, unless another grammar is already exclusive. Start and stop commands are buffered for all other grammars until the exclusive grammar is reset to SPGS_ENABLED.
Requirements
OS Versions: Windows CE .NET 4.1 and later.
Header: Sapi.h, Sapi.idl.
See Also
Send Feedback on this topic to the authors