InkCanvas.EditingModeChanged 事件
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
當 EditingMode 物件的 InkCanvas 屬性變更時,就會發生。
public:
event System::Windows::RoutedEventHandler ^ EditingModeChanged;
public event System.Windows.RoutedEventHandler EditingModeChanged;
member this.EditingModeChanged : System.Windows.RoutedEventHandler
Public Custom Event EditingModeChanged As RoutedEventHandler
事件類型
範例
下列範例會檢查 屬性是否 EditingMode 設定為 Ink 或 Select 。
void inkCanvas1_EditingModeChanged(object sender, EventArgs e)
{
if (inkCanvas1.EditingMode == InkCanvasEditingMode.Ink)
{
modeLabel.Text = "Ink";
}
else if (inkCanvas1.EditingMode == InkCanvasEditingMode.Select)
{
modeLabel.Text = "select";
}
}
Private Sub inkCanvas1_EditingModeChanged(ByVal sender As Object, ByVal e As RoutedEventArgs)
If inkCanvas1.EditingMode = InkCanvasEditingMode.Ink Then
modeLabel.Text = "Ink"
ElseIf inkCanvas1.EditingMode = InkCanvasEditingMode.Select Then
modeLabel.Text = "select"
End If
End Sub
備註
此事件會在編輯模式變更之後發生;變更會反映在 的 InkCanvas 屬性中 EditingMode 。
路由事件資訊
識別碼欄位 | EditingModeChangedEvent |
路由策略 | 鼓 泡 |
代理人 | RoutedEventHandler |