共用方式為


MouseGestureData 類別

提供滑鼠位置的相關資訊。

繼承階層架構

System.Object
  Microsoft.Windows.Design.Interaction.GestureData
    Microsoft.Windows.Design.Interaction.MouseGestureData
      Microsoft.Windows.Design.Interaction.DragGestureData

命名空間:  Microsoft.Windows.Design.Interaction
組件:  Microsoft.Windows.Design.Interaction (在 Microsoft.Windows.Design.Interaction.dll 中)

語法

'宣告
Public Class MouseGestureData _
    Inherits GestureData
public class MouseGestureData : GestureData
public ref class MouseGestureData : public GestureData
type MouseGestureData =  
    class
        inherit GestureData
    end
public class MouseGestureData extends GestureData

MouseGestureData 型別會公開下列成員。

建構函式

  名稱 說明
公用方法 MouseGestureData(EditingContext, ModelItem, ModelItem, Visual, Point, Point) 初始化 MouseGestureData 類別的新執行個體。
公用方法 MouseGestureData(EditingContext, ModelItem, ModelItem, Visual, Point, Point, DependencyObject, DependencyObject) 初始化 MouseGestureData 類別的新執行個體。

回頁首

屬性

  名稱 說明
公用屬性 Adorners 取得內容中儲存之設計工具檢視的裝飾項集合。 (繼承自 GestureData)。
公用屬性 Context 取得與這個筆勢資料相關聯的編輯內容。 (繼承自 GestureData)。
公用屬性 CurrentPosition 取得滑鼠目前的位置。
公用屬性 ImpliedSource 取得這個筆勢的來源模型。 (繼承自 GestureData)。
公用屬性 ImpliedTarget 取得這個筆勢的目標模型。 (繼承自 GestureData)。
公用屬性 PositionDelta 取得開始位置與結束位置之間的位移 (Offset)。
公用屬性 SourceAdorner 取得檢視中的來源裝飾項。 (繼承自 GestureData)。
公用屬性 SourceModel 取得這個筆勢的來源物件。 (繼承自 GestureData)。
公用屬性 StartPosition 取得滑鼠的開始位置。
公用屬性 TargetAdorner 取得檢視中的目標裝飾項。 (繼承自 GestureData)。
公用屬性 TargetModel 取得這個筆勢的目標物件。 (繼承自 GestureData)。

回頁首

方法

  名稱 說明
公用方法 Equals 判斷指定的 Object 和目前的 Object 是否相等。 (繼承自 Object)。
受保護的方法 Finalize 允許物件在記憶體回收進行回收之前,嘗試釋放資源並執行其他清除作業。 (繼承自 Object)。
公用方法靜態成員 FromEventArgs(CanExecuteToolEventArgs) CanExecuteToolEventArgs 物件提供 MouseGestureData 物件。
公用方法靜態成員 FromEventArgs(ExecutedToolEventArgs) ExecutedToolEventArgs 物件提供 MouseGestureData。
公用方法 GetHashCode 做為特定型別的雜湊函式。 (繼承自 Object)。
公用方法 GetType 取得目前執行個體的 Type。 (繼承自 Object)。
受保護的方法 MemberwiseClone 建立目前 Object 的淺層複本 (Shallow Copy)。 (繼承自 Object)。
公用方法 ToString 傳回表示目前物件的字串。 (繼承自 Object)。
公用方法 TranslatePoint 將指定的點轉譯為指定之模型的視覺座標系統。

回頁首

備註

StartPosition 屬性表示第一次按下滑鼠按鍵時的滑鼠位置。 所有位置一律在 DesignerView 的座標系統中,所以不會隨著使用者移動項目而「移動」。 這個 Decorator 是透過 coordinateReference 參數提供給 MouseGestureData 類別 (Class)。 您可以呼叫 TranslatePoint 方法,將座標轉換為不同的參照。

執行緒安全

這個型別的任何 Public static (在 Visual Basic 中為 Shared) 成員都具備執行緒安全。並非所有的執行個體成員都是安全執行緒。

請參閱

參考

Microsoft.Windows.Design.Interaction 命名空間

其他資源

了解 WPF 設計工具擴充性