使用されていません。収集したインクを認識エンジンに送信し、認識結果を表示します。PenInputPanel は Microsoft.Ink.TextInput に置き換えられました。
名前空間 : Microsoft.Ink
アセンブリ : Microsoft.Ink (Microsoft.Ink.dll 内)
構文
'宣言
<PermissionSetAttribute(SecurityAction.InheritanceDemand, Name := "FullTrust")> _
<UIPermissionAttribute(SecurityAction.Demand, Window := UIPermissionWindow.SafeTopLevelWindows)> _
<SecurityPermissionAttribute(SecurityAction.Demand, Unrestricted := True)> _
Public Sub CommitPendingInput
'使用
Dim instance As PenInputPanel
instance.CommitPendingInput()
[PermissionSetAttribute(SecurityAction.InheritanceDemand, Name = "FullTrust")]
[UIPermissionAttribute(SecurityAction.Demand, Window = UIPermissionWindow.SafeTopLevelWindows)]
[SecurityPermissionAttribute(SecurityAction.Demand, Unrestricted = true)]
public void CommitPendingInput()
[PermissionSetAttribute(SecurityAction::InheritanceDemand, Name = L"FullTrust")]
[UIPermissionAttribute(SecurityAction::Demand, Window = UIPermissionWindow::SafeTopLevelWindows)]
[SecurityPermissionAttribute(SecurityAction::Demand, Unrestricted = true)]
public:
void CommitPendingInput()
/** @attribute PermissionSetAttribute(SecurityAction.InheritanceDemand, Name = "FullTrust") */
/** @attribute UIPermissionAttribute(SecurityAction.Demand, Window = UIPermissionWindow.SafeTopLevelWindows) */
/** @attribute SecurityPermissionAttribute(SecurityAction.Demand, Unrestricted = true) */
public void CommitPendingInput()
public function CommitPendingInput()
解説
西洋言語では、手書きパネルが収集されたインクを認識エンジンに送信し、手書きパッドを消去します。複数ボックスを使用する東アジア言語では、手書きパネルが認識された文字を送信し、ボックスを消去します。認識結果は、PenInputPanel オブジェクトが結合されているコントロールに送信されます。
保留の入力がない場合や、CurrentPanel プロパティがキーボードの場合、CommitPendingInput は何も行いません。
PenInputPanel オブジェクトがアクティブでない場合、このメソッドを呼び出すとエラーが生成されます。
Microsoft® Windows® XP Tablet PC Edition 2005 を使用すると、インクはユーザーが入力したものとして認識されます。そのため、CommitPendingInput 関数は既に認識されたテキストを、認識を強制実行しないエディット コントロールに送信します。
Windows XP Tablet PC Edition 2005 を使用すると、PenInputPanel オブジェクトがアクティブでない場合、CommitPendingInput はエラーを生成しないで終了します。
![]() |
---|
部分信頼で使用している場合、このメソッドには PenInputPanel により必要とされるアクセス許可に加えて、SecurityPermissionFlag.AllFlags アクセス許可が必要です。詳細については、「Security and Trust」を参照してください。 |
例
この C# の例では、PenInputPanel オブジェクト thePenInputPanel を作成し、それを InkEdit コントロール theInkEdit に結合します。また、VisibleChanged イベント ハンドラ VisibleChanged_Event を PenInputPanel のフォームに追加します。イベント ハンドラでは、PenInputPanel オブジェクトが非表示になった場合、CommitPendingInput メソッドを呼び出すことにより、保留中の入力は認識エンジンに送信されます。
[C#]
//...
// Declare the PenInputPanel object
PenInputPanel thePenInputPanel;
public Form1()
{
// Required for Windows Form Designer support
InitializeComponent();
// Create and attach the new PenInputPanel to an InkEdit control.
thePenInputPanel = new PenInputPanel(theInkEdit);
// Add a PenInputPanelVisibleChanged event handler
thePenInputPanel.VisibleChanged +=
new PenInputPanelVisibleChangedEventHandler(VisibleChanged_Event);
}
//...
public void VisibleChanged_Event(object sender,
PenInputPanelVisibleChangedEventArgs e)
{
// Make sure the object that generated
// the event is a PenInputPanel object
if (sender is PenInputPanel)
{
PenInputPanel theSenderPanel = (PenInputPanel)sender;
// If the panel has become invisible...
if (!e.NewVisibility)
{
// Send pending input to the recognizer
theSenderPanel.CommitPendingInput();
}
}
}
この Microsoft Visual Basic® .NET の例では、PenInputPanel オブジェクト thePenInputPanel を作成し、それを InkEdit コントロール theInkEdit に結合します。また、VisibleChanged イベント ハンドラ VisibleChanged_Event を PenInputPanel のフォームに追加します。イベント ハンドラでは、PenInputPanel オブジェクトが非表示になった場合、CommitPendingInput メソッドを呼び出すことにより、保留中の入力は認識エンジンに送信されます。
[Visual Basic]
'...
' Declare the PenInputPanel object
Dim thePenInputPanel As PenInputPanel
Public Sub New()
MyBase.New()
'This call is required by the Windows Form Designer.
InitializeComponent()
' Create and attach the new PenInputPanel to an InkEdit control.
thePenInputPanel = New PenInputPanel(theInkEdit)
' Add a PenInputPanelVisibleChanged event handler
AddHandler thePenInputPanel.VisibleChanged, _
AddressOf VisibleChanged_Event
End Sub 'New
'...
Public Sub VisibleChanged_Event(sender As Object, e As _
PenInputPanelVisibleChangedEventArgs)
' Make sure the object that generated
' the event is a PenInputPanel object
If TypeOf sender Is PenInputPanel Then
Dim theSenderPanel As PenInputPanel = CType(sender, PenInputPanel)
' If the panel has become invisible...
If Not e.NewVisibility Then
' Send pending input to the recognizer
theSenderPanel.CommitPendingInput()
End If
End If
End Sub 'VisibleChanged_Event
プラットフォーム
Windows Vista
.NET Framework および .NET Compact Framework では、各プラットフォームのすべてのバージョンはサポートしていません。サポートされているバージョンについては、「.NET Framework システム要件」を参照してください。
バージョン情報
.NET Framework
サポート対象 : 3.0