InkAnalyzer が現在の分析ヒントを適用したすべての手書きノードの認識された文字列の連結を返します。
名前空間 : System.Windows.Ink
アセンブリ : IAWinFX (IAWinFX.dll 内)
構文
'宣言
Public Function GetRecognizedString As String
'使用
Dim instance As AnalysisHintNode
Dim returnValue As String
returnValue = instance.GetRecognizedString()
public string GetRecognizedString()
public:
String^ GetRecognizedString()
public String GetRecognizedString()
public function GetRecognizedString() : String
戻り値
型 : System.String
InkAnalyzer が現在の分析ヒントを適用したすべての手書きノードの認識された文字列の連結。既定値は空の文字列 ("") です。
解説
このメソッドにより返される文字列は、ヒントがリンクされた System.Windows.Ink.ContextNode オブジェクトの認識された文字列を連結することにより取得するのと同じ文字列です。認識された文字列の順序は、InkAnalyzerBaseGetRecognizedString() で使用される順序と同じです。
例
この例では、StringBuilder、notes を作成し、現在 (theInkAnalyzerWithHint という名前の) InkAnalyzer にアタッチされているすべてのヒントに関する情報を追加します。ヒントごとに、ヒントの名前、単語リスト、認識された文字列が notes に追加されます。
Dim notes As New System.Text.StringBuilder()
notes.AppendLine("List of all the current AnalysisHintNodes:")
Dim theHint As AnalysisHintNode
For Each theHint In Me.theInkAnalyzerWithHint.GetAnalysisHints()
notes.AppendLine(" Hint Name: " + theHint.Name)
If 0 < theHint.GetWordlist().Length Then
notes.Append(" - WordList: ")
Dim first As Boolean = True
Dim theWord As String
For Each theWord In theHint.GetWordlist()
If Not first Then
notes.Append(", ")
Else
first = False
End If
notes.AppendFormat("'{0}'", theWord)
Next theWord
notes.AppendLine()
Else
notes.AppendLine(" - No WordList specified")
End If
If String.Empty <> theHint.GetRecognizedString() Then
notes.AppendLine(" - Recognized string: " + theHint.GetRecognizedString())
Else
notes.AppendLine(" - No recognized string.")
End If
notes.AppendLine()
Next theHint
System.Text.StringBuilder notes = new System.Text.StringBuilder();
notes.AppendLine("List of all the current AnalysisHintNodes:");
foreach (AnalysisHintNode theHint
in this.theInkAnalyzerWithHint.GetAnalysisHints())
{
notes.AppendLine(" Hint Name: " + theHint.Name);
if (0 < theHint.GetWordlist().Length)
{
notes.Append(" - WordList: ");
bool first = true;
foreach (String theWord in theHint.GetWordlist())
{
if (!first)
{
notes.Append(", ");
}
else
{
first = false;
}
notes.AppendFormat("'{0}'", theWord);
}
notes.AppendLine();
}
else
{
notes.AppendLine(" - No WordList specified");
}
if (string.Empty != theHint.GetRecognizedString())
{
notes.AppendLine(" - Recognized string: "
+ theHint.GetRecognizedString());
}
else
{
notes.AppendLine(" - No recognized string.");
}
notes.AppendLine();
}
プラットフォーム
Windows Vista
.NET Framework および .NET Compact Framework では、各プラットフォームのすべてのバージョンはサポートしていません。サポートされているバージョンについては、「.NET Framework システム要件」を参照してください。
バージョン情報
.NET Framework
サポート対象 : 3.0