Bagikan melalui


Recognizer.Capabilities Property

Recognizer.Capabilities Property

Gets the capabilities of the Recognizer object.

Definition

Visual Basic .NET Public ReadOnly Property Capabilities As RecognizerCapabilities
C# public RecognizerCapabilities Capabilities { get; }
Managed C++ public: __property RecognizerCapabilities* get_Capabilities();

Property Value

Microsoft.Ink.RecognizerCapabilities. Values that define the capabilities of the recognizer.

This property is read-only. This property has no default value.

DontCare1 Ignores all other flags that are set.
Object2 If set, specifies the recognizer performs object recognition; otherwise, the recognizer performs text recognition.
FreeInput4 Specifies the recognizer supports free input. Ink is entered without the use of a guide, such as lines or boxes.
LinedInput8 Specifies the recognizer supports lined input, which is similar to writing on lined paper.
BoxedInput16 Specifies the recognizer supports boxed input, in which each character or word is entered in a box.
CharacterAutoCompletionInput32 Specifies the recognizer supports character Autocomplete. Recognizers that support character Autocomplete require boxed input.
RightAndDown64 Specifies the recognizer supports western and Asian languages.
LeftAndDown128 Specifies that the recognizer supports Hebrew and Arabic languages.
DownAndLeft256 Specifies the recognizer supports Asian languages.
DownAndRight512 Specifies the recognizer supports the Chinese language.
ArbitraryAngle1024 Specifies the recognizer supports text is written at arbitrary angles.
Lattice2048 Specifies the recognizer can return a lattice object.
AdviseInkChange4096 Specifies that the recognizer's background recogition can be interrupted, as in when the ink has changed.
StrokeReorder8192 Specifies that stroke order — spatial and temporal — is handled.

Remarks

A recognizer's capabilities are defined in the RecognizerCapabilities enumeration, and they include whether the recognizer supports character Autocomplete; whether it supports free, lined, or boxed input; and so on. For a complete list of recognizer capabilities, see the RecognizerCapabilities enumeration.

To determine if a recognizer has a particular capability, use a bitwise comparison operator to check for that capability. For more information about how a bitwise comparison works, see the And Operator Leave Site.

Examples

[C#]

This C# example determines if the Recognizer object, theRecognizer, supports the ArbitraryAngle capability.

using Microsoft.Ink;
// . . .
bool isArbitraryAngleSupported = false;
RecognizerCapabilities theCapabilities = theRecognizer.Capabilities;
if ((RecognizerCapabilities.ArbitraryAngle & theCapabilities) != 0)
    isArbitraryAngleSupported = true;

[Visual Basic .NET]

This Microsoft® Visual Basic® .NET example determines if the Recognizer, theRecognizer, supports the ArbitraryAngle capability.

Imports Microsoft.Ink
' . . .
Dim isArbitraryAngleSupported As Boolean = False
Dim theCapabilities As RecognizerCapabilities
theCapabilities = theRecognizer.Capabilities
If (RecognizerCapabilities.ArbitraryAngle And theCapabilities) <> 0 Then
    isArbitraryAngleSupported = True
End If

See Also