InkEdit.Recognizer - свойство
Обновлен: Ноябрь 2007
Gets or sets the Recognizer object used by the InkEdit control.
Пространство имен: Microsoft.Ink
Сборка: Microsoft.Ink (в Microsoft.Ink.dll)
Синтаксис
'Декларация
<BrowsableAttribute(False)> _
Public Property Recognizer As Recognizer
'Применение
Dim instance As InkEdit
Dim value As Recognizer
value = instance.Recognizer
instance.Recognizer = value
[BrowsableAttribute(false)]
public Recognizer Recognizer { get; set; }
[BrowsableAttribute(false)]
public:
property Recognizer^ Recognizer {
Recognizer^ get ();
void set (Recognizer^ value);
}
/** @property */
/** @attribute BrowsableAttribute(false) */
public Recognizer get_Recognizer()
/** @property */
/** @attribute BrowsableAttribute(false) */
public void set_Recognizer(Recognizer value)
public function get Recognizer () : Recognizer
public function set Recognizer (value : Recognizer)
Значение свойства
Тип: Microsoft.Ink.Recognizer
The recognizer used by the InkEdit control.
Заметки
The default recognizer that is returned is the default recognizer for the active input locale. To select the active input locale, in the Regional and Language Options in Control Panel, on the Languages tab, users click Details, and then select the Default input language.
This property is only available at run time.
This property should be changed only if the Status property returns the InkEditStatus enumeration value, Idle.
If a factoid is used for the InkEdit control, it must be reapplied after setting the Recognizer property.
Примеры
In this example, if an Recognizer object capable of recognizing Spanish is available, then the Recognizer property of the InkEdit control is set to use it.
If InkEditStatus.Idle = mInkEdit.Status Then
Const LCID_Spanish As Integer = &HC0A
' get all the Recognizers
Dim allR As Recognizers = New Recognizers()
' check each Recognizer
For Each R As Recognizer In allR
' check each supported language of the Recognizer
For Each LCID As Integer In R.Languages
' if the language == Spanish, change the Recognizer
If LCID_Spanish = LCID Then
mInkEdit.Recognizer = R
End If
Next
Next
' display the name of the recognizer in the InkEdit control
mInkEdit.Text = mInkEdit.Recognizer.Name + Environment.NewLine
End If
if (InkEditStatus.Idle == mInkEdit.Status)
{
const int LCID_Spanish = 0x0C0A;
// get all the Recognizers
Recognizers allR = new Recognizers();
// check each Recognizer
foreach (Recognizer R in allR)
{
// check each supported language of the Recognizer
foreach (int LCID in R.Languages)
{
// if the language == Spanish, change the Recognizer
if (LCID_Spanish == LCID)
{
mInkEdit.Recognizer = R;
}
}
}
// display the name of the recognizer in the InkEdit control
mInkEdit.Text = mInkEdit.Recognizer.Name + Environment.NewLine;
}
Платформы
Windows Vista
Среды .NET Framework и .NET Compact Framework поддерживают не все версии каждой платформы. Поддерживаемые версии перечислены в разделе Требования к системе для .NET Framework.
Сведения о версии
.NET Framework
Поддерживается в версии: 3.0